Fix file permissions.
For directories use 755.
For files use 644.

http://browse-tutorials.com/snippet/give-permissions-recursively-files-o...

CommentFileSizeAuthor
#2 fix_permissions_7.x_1.x-2211485-2.patch2.35 KBram4nd

Comments

fietserwin’s picture

What files and directories need their permissions to be fixed?

ram4nd’s picture

StatusFileSize
new2.35 KB

This is for 7 for an example.

fietserwin’s picture

I'm using Windows and I have no idea how to set and subsequently store and commit these permissions in git. but if your patch does just that, I will happily apply your patch and commit it.

This what I get on applying your patch:

warning: README.txt has type 100644, expected 100755
warning: canvasactions/canvasactions.inc has type 100644, expected 100755
warning: canvasactions/imagecache_canvasactions.info has type 100644, expected 100755
warning: canvasactions/imagecache_canvasactions.module has type 100644, expected 100755
warning: coloractions/imagecache_coloractions.info has type 100644, expected 100755
warning: coloractions/imagecache_coloractions.module has type 100644, expected 100755
warning: coloractions/transparency.inc has type 100644, expected 100755
warning: customactions/imagecache_customactions.info has type 100644, expected 100755
warning: customactions/imagecache_customactions.install has type 100644, expected 100755
warning: docs/brightness.png has type 100644, expected 100755
warning: docs/canvases.png has type 100644, expected 100755
warning: docs/colorshift.png has type 100644, expected 100755
warning: docs/combo.png has type 100644, expected 100755
warning: docs/overlays.png has type 100644, expected 100755
warning: docs/transparency.png has type 100644, expected 100755
warning: docs/watermark.png has type 100644, expected 100755
warning: imagecache_actions.info has type 100644, expected 100755
warning: imagefilter.inc has type 100644, expected 100755
warning: tests/imagecache_testsuite.info has type 100644, expected 100755
warning: tests/imagecache_testsuite.module has type 100644, expected 100755
warning: utility-color.inc has type 100644, expected 100755
warning: utility-form.inc has type 100644, expected 100755
warning: utility.inc has type 100644, expected 100755
warning: watermark.inc has type 100644, expected 100755

if I subsequently look at the local changes I only see 2 files listed:
- customactions/imagecache_customactions.install
- watermark.inc

dman’s picture

Version: 6.x-2.x-dev » 7.x-1.x-dev
Status: Active » Fixed

Yeah, a permissions-less (or different) file system probably won't take the change here in any meaningful way.
I could apply with

git apply fix_permissions_7.x_1.x-2211485-2.patch

and it seems to have the expected effect.
Yep, it's inappropriate (and probably an unintentional error) that a number of *files* were marked as executable.
As the patch applies clean, and I agree it does improve things technically (though the difference may not be apparent in any meaningful way)
and because I can, and Windows probably can't

I'll push this in.
https://drupal.org/commitlog/commit/6286/13094f51856b9a39688c56dd7d5ad24...
Described better at:
http://drupalcode.org/project/imagecache_actions.git/commitdiff/13094f51...

It will probably make no appreciable difference to Windows checkouts at all, or to anyone using the code right now.
It's just good practice.

Thanks for your attention to detail @ram4nd - it's valuable!

Does anyone think it's worth backporting to D6? I don't care enough, but it's easy.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.