diff --git a/10_snapper-post.hook b/10_snapper-post.hook index a6e6943..4d40c70 100644 --- a/10_snapper-post.hook +++ b/10_snapper-post.hook @@ -27,4 +27,4 @@ Target = * Description = snapper post snapshot Depends = snapper When = PostTransaction -Exec = /usr/share/libalpm/hooks.bin/snap-pac/snapper-post +Exec = /usr/bin/bash -c ". /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; post" diff --git a/10_snapper-pre.hook b/10_snapper-pre.hook index 2159406..b6979ff 100644 --- a/10_snapper-pre.hook +++ b/10_snapper-pre.hook @@ -27,4 +27,4 @@ Target = * Description = snapper pre snapshot Depends = snapper When = PreTransaction -Exec = /usr/share/libalpm/hooks.bin/snap-pac/snapper-pre +Exec = /usr/bin/bash -c ". /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; pre" diff --git a/20_snap-pac-clean.hook b/20_snap-pac-clean.hook index 4d76716..c9ca54a 100644 --- a/20_snap-pac-clean.hook +++ b/20_snap-pac-clean.hook @@ -24,4 +24,4 @@ Target = snap-pac [Action] Description = snap-pac cleanup upon removal When = PreTransaction -Exec = /usr/share/libalpm/hooks.bin/snap-pac/snap-pac-clean +Exec = /usr/bin/bash -c ". /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; clean" diff --git a/install b/install index 65f9056..6dd6d3e 100755 --- a/install +++ b/install @@ -22,14 +22,11 @@ # PKGBUILD that installs using "./install $pkgdir". INSTALL_DIR=$1 -SCRIPTS_DIR=$INSTALL_DIR/usr/share/libalpm/hooks.bin/snap-pac/ +SCRIPTS_DIR=$INSTALL_DIR/usr/share/libalpm/hooks.bin/ HOOKS_DIR=$INSTALL_DIR/usr/share/libalpm/hooks/ install -d $HOOKS_DIR install -d $SCRIPTS_DIR install -d $INSTALL_DIR/etc -install -Dm 755 snapper-pre $SCRIPTS_DIR -install -Dm 755 snapper-post $SCRIPTS_DIR -install -Dm 755 snap-pac-clean $SCRIPTS_DIR install -Dm 755 snap-pac $SCRIPTS_DIR install -Dm 644 10_snapper-pre.hook $HOOKS_DIR install -Dm 644 10_snapper-post.hook $HOOKS_DIR diff --git a/snap-pac-clean b/snap-pac-clean deleted file mode 100755 index f770549..0000000 --- a/snap-pac-clean +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash - -# snap-pac -# https://github.com/wesbarnett/snap-pac -# Copyright (C) 2016 James W. Barnett - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -source /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; clean diff --git a/snapper-post b/snapper-post deleted file mode 100755 index 97b5a9b..0000000 --- a/snapper-post +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -# snap-pac -# https://github.com/wesbarnett/snap-pac -# Copyright (C) 2016 James W. Barnett - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -# Takes a snapper post snapshot after a pacman transaction - -source /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; post diff --git a/snapper-pre b/snapper-pre deleted file mode 100755 index ec434d7..0000000 --- a/snapper-pre +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -# snap-pac -# https://github.com/wesbarnett/snap-pac -# Copyright (C) 2016 James W. Barnett - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -# Takes a snapper pre snapshot before a pacman transaction - -source /usr/share/libalpm/hooks.bin/snap-pac/snap-pac; pre