summaryrefslogtreecommitdiff
path: root/debian/vyatta-cfg.postinst.in
diff options
context:
space:
mode:
Diffstat (limited to 'debian/vyatta-cfg.postinst.in')
-rw-r--r--debian/vyatta-cfg.postinst.in8
1 files changed, 8 insertions, 0 deletions
diff --git a/debian/vyatta-cfg.postinst.in b/debian/vyatta-cfg.postinst.in
index 5585e2a..7ba4332 100644
--- a/debian/vyatta-cfg.postinst.in
+++ b/debian/vyatta-cfg.postinst.in
@@ -33,6 +33,14 @@ for bin in my_cli_bin my_cli_shell_api; do
setcap cap_sys_admin=pe $sbindir/$bin
done
+# commit hooks
+for hook in PreCommit PostCommit; do
+ d=$(cli-shell-api get${hook}HookDir)
+ if [ -n "$d" ] && [ ! -e "$d" ]; then
+ mkdir -p "$d"
+ fi
+done
+
# handle renamed file (not automatically deleted since it was "conffile")
rm -f /etc/bash_completion.d/20vyatta-cfg