gha-commit.sh twice within same action #316
This commit is contained in:
parent
2910ddfa88
commit
7c93a34795
|
@ -8,10 +8,12 @@ git status
|
|||
OUT=$(git commit -am "[skip actions] Auto-generated board" 2>&1) || echo "commit failed, finding out why"
|
||||
if echo "$OUT" | grep 'nothing to commit' || echo "$OUT" | grep 'nothing added to commit'; then
|
||||
echo "headers: looks like nothing to commit"
|
||||
# todo: NOCOMMIT is deprecated I guess? YESCOMMIT works better with multiple invocations per action
|
||||
echo "::set-env name=NOCOMMIT::true"
|
||||
exit 0
|
||||
elif echo "$OUT" | grep 'changed'; then
|
||||
echo "headers: looks like something has changed"
|
||||
echo "::set-env name=YESCOMMIT::true"
|
||||
exit 0
|
||||
else
|
||||
echo "headers: looks like something unexpected"
|
||||
|
|
Loading…
Reference in New Issue