generated from actions/typescript-action
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from tony84727/pushing_action
Use last commit as the base commit to compare when triggered by push events
- Loading branch information
Showing
6 changed files
with
87 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# test that run on each push to test the action in push workflow | ||
name: 'push-test' | ||
on: ['push'] | ||
|
||
jobs: | ||
push-test-1: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
# add a fake commit | ||
- name: Add Commit | ||
run: | | ||
mkdir testzone && \ | ||
touch testzone/touched.txt && \ | ||
git config user.name 'Github Action' && \ | ||
git config user.email '[email protected]' && \ | ||
git add testzone/touched.txt && \ | ||
git commit -m "add testzone/touched.txt" | ||
- uses: ./ | ||
id: filter | ||
with: | ||
head-ref: HEAD | ||
filters: | | ||
test: | ||
- 'testzone/*.txt' | ||
should-not-changed: | ||
- 'not-exsits' | ||
- name: Check Output | ||
run: | | ||
[[ "${{ steps.filter.outputs.test}}" = "true" ]] && \ | ||
[[ "${{ steps.filter.outputs.should-not-changed }}" = "false" ]] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters