Alexandre Aubin
88b7d77610
Display raw json content in case of exception
2019-03-04 18:58:04 +01:00
Alexandre Aubin
877fe50685
Use a finally clause to avoid duplicated code
2019-03-04 17:21:57 +01:00
Josué Tille
6ab5d71603
Add the possibility to have multiple path per hook name
2019-02-11 20:05:21 +01:00
Josué Tille
cbf2c1f82a
Merge branch 'stretch-unstable' into hook_return
2019-02-11 16:06:03 +01:00
Alexandre Aubin
81bbb62b82
[microdecision] Missing translation for key 'file_not_exist'
2019-02-04 18:27:50 +01:00
Josue-T
2f63e3ba07
Merge branch 'stretch-unstable' into hook_return
2018-12-15 21:28:51 +01:00
Alexandre Aubin
115b557b67
autopep8 + a few manual tweaks
2018-12-13 18:52:26 +00:00
Alexandre Aubin
2dd1d8ccfe
Unused errno + remaining unecessary m18n.n
2018-12-12 19:01:28 +00:00
Irina LAMBLA
4ba309a221
modif MoulinetteError to YunohostError
2018-12-12 19:01:28 +00:00
Irina LAMBLA
fab662f4ef
The rest
...
The ones that sed didn't find. Modified by hand.
2018-12-12 18:56:26 +00:00
Irina LAMBLA
0468d6b900
sed 3 lines
...
deletion of line breaks to be able to use "sed" :
sed -i "N; s@MoulinetteError(.*m18n\.n(\n* *@MoulinetteError(m18n.n(@g"
2018-12-12 18:56:26 +00:00
Irina LAMBLA
4bc3427e3e
moulinette MoulinetteError multilignes"
...
sed -i "N; s@MoulinetteError(.*m18n\.n(\n* *\(.*\)))@MoulinetteError(\1)@g" <fichiers>
2018-12-12 18:56:26 +00:00
Irina LAMBLA
f2e184d8b2
moulinette MoulinetteError oneline
2018-12-12 18:56:26 +00:00
Josué Tille
8012f12797
Fix raise error
2018-12-05 00:32:42 +01:00
Josue-T
d03cdb4e95
Merge branch 'stretch-unstable' into hook_return
2018-09-03 12:43:18 +02:00
Alexandre Aubin
64204e41da
Run hook_exec as root by default ( #522 )
2018-09-03 02:38:02 +02:00
Josué Tille
8ec6f2b81a
Fix error if hook return nothing
2018-08-30 17:49:08 +02:00
Josué Tille
e4e981c0fe
Change struct returned by hook_callback
2018-08-29 20:56:36 +02:00
Josué Tille
29bf70c57c
Add hook name in return structure in hook_callback
2018-08-29 19:02:30 +02:00
Josué Tille
b7554dec21
Use json for return
2018-08-29 18:45:48 +02:00
Josué Tille
70d0f8a68f
Add return value in hook_exec
2018-08-29 18:44:45 +02:00
Alexandre Aubin
f7563b2cb4
Merge branch 'stretch-unstable' into app-stdinfo
2018-08-22 18:42:23 +02:00
Laurent Peuch
f35e3ef055
[enh] can run the action of an app
2018-06-22 04:47:32 +02:00
Laurent Peuch
274a219fdc
[enh] allow hook_exec to have custom callbacks
2018-06-22 04:37:08 +02:00
ljf
8e8d8e54ab
[enh] Enable ynh_info by default
2018-06-11 11:56:54 +02:00
Alexandre Aubin
91483f3896
Reflag some messages as info or debug
2018-06-01 21:52:19 +00:00
Alexandre Aubin
b8d8f72e36
[enh] Add an optional stdinfo output for stuff ran with hook_exec
2017-10-29 23:19:52 +01:00
Laurent Peuch
83971afb9c
[mod] pep8 on hooks.py
2017-08-20 21:19:04 +02:00
Laurent Peuch
baf0d098f5
[mod] explicitely import previously globals magic variables
2017-07-25 21:32:20 +02:00
ljf (zamentur)
afe28470c0
[enh] Add execution dir in env on hook exec ( #293 )
...
* [enh] Add execution dir in env on hook exec
* [enh] YNH_EXECUTION_DIR become YNH_CWD
* [fix] Hook exec with no env fail
* [enh] Remove dead condition
2017-05-03 19:11:01 +02:00
Laurent Peuch
76a7a36c62
[enh] run hooks as root
2017-03-05 16:41:53 +01:00
Laurent Peuch
0122cbd432
[mod] remove unused import
2017-03-05 16:41:02 +01:00
Laurent Peuch
33e101b588
[mod] change behavior, admin by default, as to explicitly set root as user
2017-03-05 16:41:02 +01:00
Laurent Peuch
b0730d8463
[enh] defaulting running hook_exec as root
2017-03-05 16:41:02 +01:00
Laurent Peuch
f6c7702dfa
[mod] rename all global variables to uppercase
2017-02-12 03:34:15 +01:00
Laurent Peuch
110d481cd1
[mod] remove unused imports
2016-12-03 12:00:55 +01:00
Laurent Peuch
365f7694a9
[enh] display file path on file_not_exist error
2016-06-23 18:36:21 +02:00
Jérôme Lebleu
b756f4d1eb
[fix] Escape arguments and env values in hook_exec (bugfix #377 )
2016-05-30 12:10:39 +02:00
Jérôme Lebleu
048ed3b0ea
[fix] Raise proper MoulinetteError exception in hook_exec
2016-05-29 23:38:35 +02:00
Jérôme Lebleu
f09ab43eb8
[fix] Print string error of MoulinetteError in hook_callback
2016-05-21 21:21:20 +02:00
Jérôme Lebleu
c3fd005027
[enh] Allow to set env var for executed hooks in hooks_callback
2016-04-30 17:15:17 +02:00
Jérôme Lebleu
aae59b1d6e
[enh] Small changes to env prepending in hook_exec
2016-04-28 21:03:22 +02:00
Julien Malik
c5d1ef981b
[enh] Set env var for each app script and rename app variables
2016-04-28 21:03:17 +02:00
Julien Malik
7ce7d6fc15
[enh] Support passing env var to hook_exec
2016-04-28 20:43:22 +02:00
Jérôme Lebleu
3ed502894c
[fix] Skip hidden and temp files in hook_list
2016-04-10 19:20:40 +02:00
Jérôme Lebleu
a26d921c0c
[fix] Formatting 'args' in hook_callback is useless
2016-04-10 16:50:39 +02:00
Jérôme Lebleu
cf077a50aa
[enh] Add pre/post script execution callbacks to hook_callback
2016-04-10 16:48:46 +02:00
Jérôme Lebleu
de08c14aa1
[enh] Allow to set script execution directory in hook_exec
2016-03-28 21:49:11 +02:00
opi
4cabb2f7f9
[enh] Use named arguments with m18n.
2016-03-27 15:56:41 +02:00
opi
7999293438
[enh] Display hook path on error message.
2016-03-27 11:26:41 +02:00