new container image
parent
827d7340f6
commit
85980ee060
@ -0,0 +1,4 @@
|
|||||||
|
FROM alpine/git
|
||||||
|
|
||||||
|
COPY ./smart-commit /bin/smart-commit
|
||||||
|
ENTRYPOINT ["sh /bin/smart-commit"]
|
@ -0,0 +1,10 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
STATUS=$(git status --porcelain)
|
||||||
|
STATUS_LEN=${#STATUS}
|
||||||
|
if [ $STATUS_LEN = 0 ]; then
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
git add .
|
||||||
|
git commit -qm "CI/CD Commit: $(date -Iseconds)"
|
||||||
|
fi
|
Loading…
Reference in New Issue