git-diff check happens post-git-add; the check needs to happen vs. the staged files, if not, git-diff will always be empty

pull/201/head
InverseBot 2016-02-25 10:20:26 -05:00
parent b294c5381a
commit 795ec46c81
1 changed files with 1 additions and 1 deletions

View File

@ -26,7 +26,7 @@ prod:
grunt --stack build
git update-index --no-assume-unchanged $(CSS_FILES) $(JS_FILES) $(JS_LIB_FILES)
git add -f $(CSS_FILES) $(JS_FILES) $(JS_LIB_FILES)
@if ! git diff --quiet --exit-code; then \
@if ! git diff --cached --quiet --exit-code; then \
git commit -m "(js/css) Update generated files"; \
else \
echo "Nothing to commit; skipping git-commit"; \