aboutsummarylogtreecommitdiffstats
path: root/10-zectl-pre.hook
diff options
context:
space:
mode:
authoreoli3n2020-05-11 12:01:08 +0200
committereoli3n2020-05-11 12:01:08 +0200
commit51b4f16186351174d0dcd43504e2d62a454cb8e0 (patch)
tree4446c75d6aa1e781b8cbd3fd39681b9266b10b93 /10-zectl-pre.hook
downloadaur-51b4f16186351174d0dcd43504e2d62a454cb8e0.tar.gz
added first files
Diffstat (limited to '10-zectl-pre.hook')
-rw-r--r--10-zectl-pre.hook11
1 files changed, 11 insertions, 0 deletions
diff --git a/10-zectl-pre.hook b/10-zectl-pre.hook
new file mode 100644
index 000000000000..69852b4dedd6
--- /dev/null
+++ b/10-zectl-pre.hook
@@ -0,0 +1,11 @@
+[Trigger]
+Operation = Remove
+Operation = Install
+Operation = Upgrade
+Type = Package
+Target = *
+
+[Action]
+Description = Create a boot environment
+When = PreTransaction
+Exec = /usr/bin/bash -c 'if [[ $(/usr/bin/zectl get -H pacmanhook) =~ yes ]];then /usr/share/libalpm/scripts/zectl-prune ; fi'