index : devtools32 | |
Archlinux32 fork of devtools | gitolite user |
summaryrefslogtreecommitdiff |
author | Andreas Baumann <mail@andreasbaumann.cc> | 2024-04-21 10:18:55 +0200 |
---|---|---|
committer | Andreas Baumann <mail@andreasbaumann.cc> | 2024-04-21 10:18:55 +0200 |
commit | 2dc7a161a09518edae9e04a77fca569460d6a560 (patch) | |
tree | 5c893311826fc1ae7090352fb2f17a2d3d3a560e /src/lib/aur | |
parent | a1ca197bc99c2d5c2977630cc4c9dbfd5461d9c1 (diff) | |
parent | 05bea3e922aa7aec5cba3242d3f34b5c10fad24e (diff) |
-rw-r--r-- | src/lib/aur/drop-from-repo.sh | 13 |
diff --git a/src/lib/aur/drop-from-repo.sh b/src/lib/aur/drop-from-repo.sh index 6ebe12a..0e9cab4 100644 --- a/src/lib/aur/drop-from-repo.sh +++ b/src/lib/aur/drop-from-repo.sh @@ -92,14 +92,19 @@ pkgctl_aur_drop_from_repo() { fi for path in "${paths[@]}"; do - if ! realpath=$(realpath -e "${path}"); then + # resolve symlink for basename + if ! realpath=$(realpath --canonicalize-existing -- "${path}"); then die "No such directory: ${path}" fi + # skip paths that are not directories + if [[ ! -d "${realpath}" ]]; then + continue + fi pkgbase=$(basename "${realpath}") pkgbase=${pkgbase%.git} - if [[ ! -d "${path}/.git" ]]; then + if [[ ! -d "${realpath}/.git" ]]; then die "Not a Git repository: ${path}" fi @@ -136,9 +141,9 @@ pkgctl_aur_drop_from_repo() { if (( FORCE )); then AUR_OVERWRITE=1 \ GIT_SSH_COMMAND="ssh -o SendEnv=AUR_OVERWRITE" \ - git push --force origin master + git push --force --no-follow-tags origin master else - git push origin master + git push --no-follow-tags origin master fi # update the local default branch in case this clone is used in the future |