feat: print mainbranch to stderr

This commit is contained in:
Rob Watson 2023-09-14 21:46:28 +02:00
parent 25dd230b9b
commit 21118ee46e
1 changed files with 4 additions and 0 deletions

View File

@ -5,11 +5,15 @@
set -e set -e
if git branch -l | grep -q "main"; then if git branch -l | grep -q "main"; then
>&2 echo "mainbranch: selected branch main"
sleep 0.5
echo "main" echo "main"
exit 0 exit 0
fi fi
if git branch -l | grep -q "master"; then if git branch -l | grep -q "master"; then
>&2 echo "mainbranch: selected branch master"
sleep 0.5
echo "master" echo "master"
exit 0 exit 0
fi fi