-
-
Notifications
You must be signed in to change notification settings - Fork 16
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
[directory permissions] tar screwed on windows ? #15
Comments
@ctalkington Thoughts? This modules just passes the file paths too |
I tried to pass some options to the tar() function.... .pipe(tar(PACKAGE+'.tar'),{"mode":0755}) but without success... |
i havent had any other reports of issue with tar permissions. for the most part archiver wraps tar-stream and since your module is using all the logic archiver runs on it comes from this block |
just nm idea - is maybe in this codeblock the problem ?
... |
don't think thats the issue; this module also does some logic it might be good to provide a sample repo to recreate and the tar produced, luckily tar is easier to read than zip. |
@gkathan ⬆️ |
I'm afraid I have the same problem: after tar is pushed, can't untar it on the server because |
@dadouf ⬇️
|
according to https://github.com/archiverjs/node-archiver/blob/master/lib/core.js#L204 return gulp.src(_src)
.pipe(tar(PACKAGE+'.tar', {mode: null}))
.pipe(gzip())
.pipe(gulp.dest(DIST)); |
We experienced the same permissions problem on our project at work. |
+1 @obingo suggestion worked a treat. Shame I didn't find it sooner -_- |
Great That works fine Many thanks |
+1 Thanks for the suggestion. @obingo |
@obingo thank you. Was wondering why i have different permissions, but now everything works as it should on windows machine. @sindresorhus maybe you could add a little note about |
+1
|
Maybe that should be set to |
This plugin just uses the |
The above recommended workaround fixed the directory execute permissions for me, but it broke execute permissions I was adding to some other files (bash/script files that are packaged in the tarball) using gulp-chmod. Fortunately I was able to use gulp-chmod to solve the directory permission issue without disturbing permissions I'd set on other files. This is an alternative workaround to the Here is an example:
|
I'm having the same issue and the However I would like to point out that this goes beyond just a missing 'x' bit on directories. It causes a serious security issue because some of my files are randomly getting 'rw-rw-rw' permissions, that is, they are world writable upon extraction! The 7zip screenshot confirms that this is how the permissions are stored in the tar.gz. Noteworthy: Not all entries are affected, just some. However it seems quite random because neither Windows' property dialog, nor cygwin, nor mingw show anything justifying 'rw-rw-rw-' on any of those entries. In fact all three show the exact same permissions on all files (except for 'x' of course). |
|
hej,
I am using gulp-tar within a auto-deploy build chain for an express application, and it works fine when using it on linux machines => unfortunately i also have to make it run on windows boxes:
.....
return gulp.src(_src)
.pipe(tar(PACKAGE+'.tar'))
.pipe(gzip())
.pipe(gulp.dest(DIST));
....
tar -zxvf PACKAGE.tar.gz
any advice ?
greetings from vienna/austria
gerold.
The text was updated successfully, but these errors were encountered: