dotfiles/bin/aursync

17 lines
474 B
Plaintext
Raw Normal View History

2021-06-03 15:10:35 +02:00
#!/bin/bash
2021-07-08 14:57:18 +02:00
if [ -d "$HOME/aur/" ]; then
cd "$HOME/aur/custom-repo/x64_86" || exit
repo-add -q custom.db.tar.gz ./*.pkg.*
if [[ "$#" -eq 1 ]]; then
aur sync --repo custom --root "$(pwd)" --no-view -u "$1" >/dev/null
else
aur sync --repo custom --root "$(pwd)" --no-view -u >/dev/null
fi
mv custom.db.tar.gz custom.db
mv custom.files.tar.gz custom.files
git add .
git commit -a -q -m "$(date +"%F %T")"
git push -q
fi