@@ -37,12 +37,12 @@ runs:
3737 GITHUB_TOKEN : ${{inputs.github-token}}
3838 REPOSITORY : ${{github.repository}}
3939 BRANCH_NAME_PREFIX : ${{inputs.branch-name-prefix}}
40- if : steps.diff.outputs.result != '' && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
40+ if : steps.diff.outputs.result != '' && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'push' || github.event_name == ' schedule' || github.event_name == 'workflow_dispatch')
4141 run : ${{ github.action_path }}/scripts/action/push.sh
4242 shell : bash
4343 - name : Set org name
4444 uses : actions/github-script@v6.3.3
45- if : github.event_name == 'pull_request' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
45+ if : github.event_name == 'pull_request' || github.event_name == 'push' || github.event_name == ' schedule' || github.event_name == 'workflow_dispatch'
4646 id : set_org_name
4747 with :
4848 github-token : ${{inputs.github-token}}
5252 return script()
5353 - name : Get PullRequests
5454 uses : actions/github-script@v6.3.3
55- if : steps.diff.outputs.result != '' && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
55+ if : steps.diff.outputs.result != '' && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'push' || github.event_name == ' schedule' || github.event_name == 'workflow_dispatch')
5656 id : get_pull_requests
5757 env :
5858 ORG_NAME : ${{steps.set_org_name.outputs.result}}
6565 # pushしたブランチでPRを作る
6666 - name : Create PullRequest
6767 uses : actions/github-script@v6.3.3
68- if : steps.diff.outputs.result != '' && steps.get_pull_requests.outputs.result == 0 && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
68+ if : steps.diff.outputs.result != '' && steps.get_pull_requests.outputs.result == 0 && ((github.event_name == 'pull_request' && github.event.action != 'closed') || github.event_name == 'push' || github.event_name == ' schedule' || github.event_name == 'workflow_dispatch')
6969 id : create_pull_request
7070 env :
7171 ORG_NAME : ${{steps.set_org_name.outputs.result}}
9292 # 既にformat修正のPRがある状態で、手動でformatを修正した場合、format修正のPRを閉じる
9393 - name : Close PullRequest
9494 uses : actions/github-script@v6.3.3
95- if : (github.event_name == 'pull_request' && (github.event.action == 'closed' || steps.diff.outputs.result == '')) || ((github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && steps.diff.outputs.result == '')
95+ if : (github.event_name == 'pull_request' && (github.event.action == 'closed' || steps.diff.outputs.result == '')) || ((github.event_name == 'push' || github.event_name == ' schedule' || github.event_name == 'workflow_dispatch') && steps.diff.outputs.result == '')
9696 env :
9797 ORG_NAME : ${{steps.set_org_name.outputs.result}}
9898 BRANCH_NAME_PREFIX : ${{inputs.branch-name-prefix}}
0 commit comments