Skip to content

Commit d5cb031

Browse files
committed
Fix a bug where an update with only added files will fail to commit and notify. Need to add the files first and then do a cached diff.
1 parent b3d5b6c commit d5cb031

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

config-tracker

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,9 @@ update() {
7575
# Commits changes in repo dir.
7676
#
7777
commit() {
78-
message="$(git diff --name-status)"
79-
git add -A && git commit -q -m "$message" >/dev/null
78+
git add -A
79+
message="$(git diff --cached --name-status)"
80+
git commit -q -m "$message" >/dev/null
8081
}
8182

8283
#

0 commit comments

Comments
 (0)