Skip to content

Commit

Permalink
🔧 Change main branch to master branch on workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
nanpuhaha committed Dec 18, 2022
1 parent 8fba170 commit f6a781f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 13 deletions.
26 changes: 15 additions & 11 deletions .github/workflows/pre-commit-2.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name: pre-commit
name: pre-commit-2

on:
pull_request:
branches: [main]
branches: [master]
types: [opened, synchronize, closed]
push:
branches: [main]
branches: [master]

jobs:
pre-commit:
Expand All @@ -30,22 +30,26 @@ jobs:

- name: Show File Changes
run: |
echo 'files.json'
echo -e 'files.json'
cat $HOME/files.json
echo 'files_modified.json'
echo -e '\nfiles_modified.json\n'
cat $HOME/files_modified.json
echo 'files_added.json'
echo -e '\nfiles_added.json'
cat $HOME/files_added.json
echo 'files_removed.json'
cat $HOME/files_removed.json
echo '${{ steps.file_changes.outputs.files}}'
echo '${{ steps.file_changes.outputs.files_modified}}'
echo '${{ steps.file_changes.outputs.files_added}}'
echo '${{ steps.file_changes.outputs.files_removed}}'
echo '${{ steps.file_changes.outputs.files }}'
echo '${{ steps.file_changes.outputs.files_modified }}'
echo '${{ steps.file_changes.outputs.files_added }}'
echo '${{ steps.file_changes.outputs.files_removed }}'
- name: steps.file_changes.outputs.files
run: |
echo '${{ steps.file_changes.outputs.files }}'
# https://github.com/marketplace/actions/pre-commit
# https://github.com/cloudposse/github-action-pre-commit
- uses: pre-commit/action@v3.0.0
with:
extra_args: --files ${{ steps.file_changes.outputs.files}}
extra_args: --files ${{ steps.file_changes.outputs.files }}
# https://github.com/pre-commit/action/issues/7
4 changes: 2 additions & 2 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ name: pre-commit

on:
pull_request:
branches: [main]
branches: [master]
types: [opened, synchronize, closed]
push:
branches: [main]
branches: [master]

jobs:
pre-commit:
Expand Down

0 comments on commit f6a781f

Please sign in to comment.