Skip to content

Keep monthly coupon distribution alive #22

Keep monthly coupon distribution alive

Keep monthly coupon distribution alive #22

Workflow file for this run

name: Keep monthly coupon distribution alive
on:
schedule:
- cron: "42 0 1 * *"
jobs:
keep_alive:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Add or update .keepalive
run: echo $(date +'%s') > .keepalive
- name: Commit .keepalive
run: |
git config --local user.email "[email protected]"
git config --local user.name "JuiceShopBot"
if [ -n "$(git status --porcelain)" ]; then
git add .
git commit -m "Bump keep-alive on $(date +'%B %d, %Y %T (%Z)')"
git push origin $(git branch --show-current)
else
echo "Oops, seems the keep-alive failed!"
exit 1
fi