pcardona34 / moodle-filter_jecho

Filter jecho for Moodle 2.8
0 stars 0 forks source link

File permissions within the package #2

Open mudrd8mz opened 9 years ago

mudrd8mz commented 9 years ago

I just found that some files/dirs inside the ZIP uploaded into https://moodle.org/plugins/pluginversion.php?id=8267 have permissions set to 0700 which caused troubles for me after unzipping the package:

-rw-r--r-- 1 mudrd8mz mudrd8mz 1338 Mar 26 00:43 filterlocalsettings.php
-rw-r--r-- 1 mudrd8mz mudrd8mz 4247 Mar 26 00:43 filter.php
drwx------ 6 mudrd8mz mudrd8mz 4096 Mar 26 22:16 jecho
drwx------ 8 mudrd8mz mudrd8mz 4096 Mar 26 22:16 lang
-rw-r--r-- 1 mudrd8mz mudrd8mz 3842 Mar 26 00:43 LISEZMOI.txt
-rw-r--r-- 1 mudrd8mz mudrd8mz 3331 Mar 26 00:43 README.txt
-rw-r--r-- 1 mudrd8mz mudrd8mz 1051 Mar 26 00:43 settings.php
-rw-r--r-- 1 mudrd8mz mudrd8mz 1629 Mar 26 23:37 version.php

See that the group does not have access to the lang directory which can cause troubles during the installation in some situations.

If you are packaging the ZIP yourself (instead of letting the Github do it for you), please make sure to set the correct files permission.

pcardona34 commented 9 years ago

The Zip is made by Github, but in my computer, the repository is outside Moodle and I made copies of the modified files into Moodle to update the view. I was afraid to loose my files if I developed those directly in Moodle. Maybe I am doing all the wrong way. Can You explain to me the right method and where to develop the filter and how not to loose it if I do uninstall-install again the filter to test the installation ?

mudrd8mz commented 9 years ago

It's not a problem to keep the local clone outside the Moodle's root. Just make sure the dirs and files have common u=rwX,go=rX permissions set before packaging. Regarding the workflow, it should be pretty safe to keep the DEV version of the plugin inside Moodle. On uninstallation, it always asks for confirmation before it deletes the files (IIRC, even then it moves them into a temporary trash directory instead of actually removing them). Additionally, if the plugin is recognized as a Git checkout, Moodle refuses to remove the files - exactly for the reasons you describe.

pcardona34 commented 9 years ago

Hi, Thanks for those aknowledgements. Now I am working on the i18n of the generator. I will go back soon to propose a better filter package Le 7 avr. 2015 20:40, "David Mudrák" notifications@github.com a écrit :

It's not a problem to keep the local clone outside the Moodle's root. Just make sure the dirs and files have common u=rwX,go=rX permissions set before packaging. Regarding the workflow, it should be pretty safe to keep the DEV version of the plugin inside Moodle. On uninstallation, it always asks for confirmation before it deletes the files (IIRC, even then it moves them into a temporary trash directory instead of actually removing them). Additionally, if the plugin is recognized as a Git checkout, Moodle refuses to remove the files - exactly for the reasons you describe.

— Reply to this email directly or view it on GitHub https://github.com/pcardona34/moodle-filter_jecho/issues/2#issuecomment-90694046 .