Skip to content

hook

hook #1518

Workflow file for this run

name: hook
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *' # UTC時刻で日本時間の0:00
jobs:
build-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: true
- name: Check submodule update
id: check
run: |
git submodule update --remote
git diff --quiet || echo "isChanged=true" >> $GITHUB_ENV
- name: Commit and push if changes
if: ${{ env.isChanged == 'true' }}
run: |
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
git commit -am "🤖: Update submodules"
git push
# コミットすることでVercelのCIが実行されるためwebhookが不要
# - name: Webhook
# if: ${{ env.isChanged == 'true' }}
# uses: joelwmale/webhook-action@master
# with:
# url: ${{ secrets.VERCEL_WEBHOOK }}