mirror of
https://codeberg.org/privacy1st/arch
synced 2024-12-23 01:16:04 +01:00
exit if no new pkgs
This commit is contained in:
parent
32c2181331
commit
2f1ed70cb1
@ -2,7 +2,7 @@
|
||||
_pkgname=repo
|
||||
_reponame=arch-pkg
|
||||
pkgname="de-p1st-$_pkgname"
|
||||
pkgver=0.1.2
|
||||
pkgver=0.1.3
|
||||
pkgrel=1
|
||||
pkgdesc="Bash script to manage remote Arch Linux repository"
|
||||
arch=('any')
|
||||
|
@ -10,6 +10,12 @@ cd "${LOCAL_PKG_DIR}" || exit
|
||||
rsync --ignore-existing --out-format="%n" --dry-run \
|
||||
./*.pkg.tar.{xz,zst} "${REMOTE_SSH_HOST}":"${REMOTE_PKG_DIR}" > new-pkg.txt || exit
|
||||
|
||||
# if there are no new packages, exit
|
||||
if [ ! -s new-pkg.txt ]; then
|
||||
echo "No new packages.";
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
|
||||
# transfer new packages using rsync
|
||||
rsync --ignore-existing --progress --human-readable \
|
||||
|
Loading…
Reference in New Issue
Block a user