2

I have build a github action, which config as

name: clock-in
on:
  workflow_dispatch:
  push:
    paths:
      - 'src/github/log/*'

jobs:
  clock-in:
    runs-on: ubuntu-latest
    steps:
      - ...
      - run: ./src/github/push.sh

and the push.sh

#! /bin/bash

remote_repo="https://${GITHUB_ACTOR}:${GH_TOKEN}@github.com/${GITHUB_REPOSITORY}.git" # remote repo address

git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config user.name "GitHub Actions"

git add .
git commit -m "update clockin log "
git push

I wish that the github action can be triggered when 'src/github/log/*' file changed and pushed. however, when I make a push, it work normally, but when github action push the change, the new acion is not triggered. How I can make the action triggered when the push comes from github action

LiuKairui
  • 21
  • 1
  • 2
    Does this answer your question? [GitHub Actions on release created workflow trigger not working](https://stackoverflow.com/questions/69063452/github-actions-on-release-created-workflow-trigger-not-working) – rethab May 20 '22 at 05:14

0 Answers0