-
-
Notifications
You must be signed in to change notification settings - Fork 47
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
Unzip doesn't work on macOS with links #79
Comments
Since it works if you use |
I've looked into the issue more and found out why this doesn't work. The problem is that In // using gulp#4.0
var contents = file.stat && file.stat.isSymbolicLink() ? file.symlink : file.contents;
if (file.isStream()) {
zip.addReadStream(contents, pathname, stat);
}
if (file.isBuffer()) {
zip.addBuffer(contents, pathname, stat);
} It is possible to simply copy the linked file instead of preserving the link (just like the modified var stat = {
compress: opts.compress,
mtime: file.stat ? file.stat.mtime : new Date(),
mode: file.stat ? file.stat.mode : null
};
if (file.stat && file.stat.isSymbolicLink()) {
// unable to find the correct mode
// maybe use the default one?
stat.mode = 0100664;
} |
Hi everyone, I'm having a problem that could be related to this issue, but I don't know exactly what it is, so If you guys know something about it, please let me know. This is what I have today, which I select the files and copy to another location.
In my tests this is working, the files and folders are copied to the destination. But when I unzip the zip file on server (Google Cloud Platform) that structure mess up just like this
So... anyone? |
gulp-zip has issues on mac e.g sindresorhus/gulp-zip#79
I have an issue where Did anyone find a solution for this? @sindresorhus |
When I zip a soft link to a larger file (>1KB), unzip stop working (either using Archive Utility or
unzip
).macOS version: 10.12
gulp-zip
version: 3.2.0Steps to reproduce
gulp-zip
.file is roughly 1KB file with generated Lorem ipsum
link is a soft link to it (
ln -s file link
)Slightly modified version of gulp-tar (only changed #L14 from
var archive = archiver('tar');
tovar archive = archiver('zip');
) unzips fine however it doesn't preserve the link (the file and link are identical files after zip + unzip).Original files:
After zip + unzip (using modified
gulp-tar
package)The text was updated successfully, but these errors were encountered: