server-scripts/aur-add
2014-10-19 17:27:33 +02:00

15 lines
305 B
Bash
Executable File

#!/bin/bash
if [ -e $1 ]; then
pkg=/tmp/$1
cp $1 $pkg
sudo chown repo:repo $pkg
shift
sudo -u repo HOME=/data/repo local-repo repo -a $pkg "$@"
else
sudo -u repo HOME=/data/repo local-repo repo -A "$@"
fi
[[ "$?" != "0" ]] && exit $?
echo Now you can install the package
echo $ pacman -Sy $@