Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

unzip.js fails to unzip Foo.app inside of Foo.zip #11

Closed
springmeyer opened this Issue May 12, 2011 · 4 comments

2 participants

Dane Springmeyer Clifton Cunningham
Dane Springmeyer
Owner

Reason is that the directory of Foo.app is not created (on osx) because it is interpreted as a filename. So, need to find a more robust method of determining whether to create folders.

d:Build dane$ unzip.js TermKit.zip 

fs.js:221
  return binding.open(path, stringToFlags(flags), mode);
                 ^
Error: EBADF, Bad file descriptor 'TermKit.app/'
    at Object.openSync (fs.js:221:18)
    at /Users/dane/.nvm/v0.4.7/lib/node/.npm/zipfile/0.1.8/package/bin/unzip.js:29:21
d:Build dane$ coda /Users/dane/.nvm/v0.4.7/lib/node/.npm/zipfile/0.1.8/package/bin/unzip.js
Dane Springmeyer

@clintonc - cool, thanks for taking a look. Note that this is not a problem core to the bindings, but rather the convenience command line script provided to go with the module. More robust usage could be plucked from https://github.com/mapbox/millstone/blob/master/lib/millstone.js#L112-163

Clifton Cunningham

Thanks - just realised after forking it and trying to find where folder vs file was managed :) Will apply that fix to our usage in calipso (https://github.com/cliftonc/calipso/blob/master/lib/cli/Download.js#L323) and then do the same to the CLI script here.

Cheers,
Clifton

Dane Springmeyer
Owner

closing, nothing actionable here.

Dane Springmeyer springmeyer closed this August 09, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.