mirror of
https://codeberg.org/guix/guix.git
synced 2026-01-25 12:05:19 -06:00
etc: pre-push Git hook: Make portable to current Debian.
Closes #64 The ;& operator was introduced in POSIX.1-2024 "Issue 8", from 2024, but is not yet available in Debian's dash shell. * etc/git/pre-push: Duplicate the handling of our two canonical Git repo URLs. Change-Id: I1125810c9f2d6fb9a99f7220d971cc38387989d3
This commit is contained in:
parent
da81ce890c
commit
96da4def78
1 changed files with 19 additions and 17 deletions
|
|
@ -36,23 +36,25 @@ do
|
|||
;;
|
||||
esac
|
||||
|
||||
# Only use the hook when pushing to upstream.
|
||||
case "$2" in
|
||||
*.gnu.org*)
|
||||
echo "adjust remote: repo was migrated to codeberg"
|
||||
exit 127
|
||||
;;
|
||||
*codeberg.org/guix/*)
|
||||
set -e
|
||||
guix git authenticate
|
||||
exec make check-channel-news
|
||||
exit 127
|
||||
;;
|
||||
*)
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
# Only use the hook when pushing to upstream.
|
||||
case "$2" in
|
||||
*.gnu.org*)
|
||||
set -e
|
||||
guix git authenticate
|
||||
exec make check-channel-news
|
||||
exit 127
|
||||
;;
|
||||
*codeberg.org/guix/*)
|
||||
set -e
|
||||
guix git authenticate
|
||||
exec make check-channel-news
|
||||
exit 127
|
||||
;;
|
||||
*)
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
|
||||
exit 0
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue