Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decompressing on MacOS node v17.0.1 creates file that fails to execute #73

Open
nsainaney opened this issue Oct 28, 2021 · 0 comments
Open

Comments

@nsainaney
Copy link

I have tested using the following:

import DecompressZip from 'decompress-zip'
import extract from 'extract-zip'
import path from 'path'

extract('ngrok.zip', { dir: path.resolve('~/ezip')}).then(_ => console.log('DONE'))

var unzipper = new DecompressZip('ngrok.zip')

unzipper.on('error', function (err) {
    console.log('Caught an error');
});

unzipper.on('extract', function (log) {
    console.log('Finished extracting');
});

unzipper.on('progress', function (fileIndex, fileCount) {
    console.log('Extracted file ' + (fileIndex + 1) + ' of ' + fileCount);
});

unzipper.extract();

The ngrok in ./ezip/ngrok works but the one extracted using decompress-zip fails results in:

./ngrok
[1]    52121 killed     ./ngrok

I'm on MacOS 11.6 (Big Sur)

@nsainaney nsainaney changed the title Decompressing on MacOS node v17.0.1 creates a corrupt binary Decompressing on MacOS node v17.0.1 creates file that fails to execute Oct 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant