33 lines
1.3 KiB
Bash
Executable file
33 lines
1.3 KiB
Bash
Executable file
#!/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.
|
|
|
|
# Installation script. First argument is the root directory. For use with a
|
|
# PKGBUILD that installs using "./install $pkgdir".
|
|
|
|
INSTALL_DIR=$1
|
|
SCRIPTS_DIR=$INSTALL_DIR/usr/share/libalpm/hooks.bin/snap-pac
|
|
HOOKS_DIR=$INSTALL_DIR/usr/share/libalpm/hooks/
|
|
install -d $HOOKS_DIR
|
|
install -d $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
|
|
install -Dm 644 20_snap-pac-clean.hook $HOOKS_DIR
|
|
install -Dm 644 LICENSE "$INSTALL_DIR/usr/share/licenses/snap-pac/LICENSE"
|