summaryrefslogtreecommitdiff
path: root/bin/gitify
diff options
context:
space:
mode:
Diffstat (limited to 'bin/gitify')
-rwxr-xr-xbin/gitify7
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/gitify b/bin/gitify
index 55ddff8..a05ae97 100755
--- a/bin/gitify
+++ b/bin/gitify
@@ -41,8 +41,9 @@ main() {
dirpart="${dirpart//_/\/}"
branch=$dirpart
+ newbranch=true
git checkout PROGRAMS/CVTUTF
- git checkout -b "$branch" || true
+ git checkout -b "$branch" || newbranch=false
git checkout "$branch"
rm -f -- * .metadata.txt
@@ -60,7 +61,7 @@ main() {
cp "$listingdir/metadata.txt" .metadata.txt
fi
- if [[ -n "$(git status -s .)" ]]; then
+ if $newbranch || [[ -n "$(git status -s .)" ]]; then
if [[ "$time" = *99 ]]; then
msg="Synthesized listing: ${time} ${dirpart}"
time="${time%99}00"
@@ -72,7 +73,7 @@ main() {
git add .
export GIT_AUTHOR_DATE=$gitdate
export GIT_COMMITTER_DATE=$gitdate
- git commit -m "$msg"
+ git commit --allow-empty -m "$msg"
fi
done
}