3
0
Fork 0
mirror of https://github.com/tj-actions/changed-files synced 2024-12-17 03:47:20 +00:00

Merge pull request #14 from tj-actions/changed-triggered-events-test-action

Update test.yml
This commit is contained in:
Tonye Jack 2021-04-04 09:08:38 -04:00 committed by GitHub
commit 4c551d94e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,9 +1,6 @@
name: CI name: CI
on: on:
push:
branches:
- main
pull_request: pull_request:
branches: branches:
- main - main
@ -16,15 +13,12 @@ jobs:
- name: Checkout - name: Checkout
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Run changed-files with defaults - name: Run changed-files with defaults
if: github.event_name == 'pull_request'
id: changed-files id: changed-files
uses: ./ uses: ./
- name: Show output - name: Show output
if: github.event_name == 'pull_request'
run: | run: |
echo "${{ toJSON(steps.changed-files.outputs) }}" echo "${{ toJSON(steps.changed-files.outputs) }}"
- name: List all modified files - name: List all modified files
if: github.event_name == 'pull_request'
run: | run: |
for file in "${{ steps.changed-files.outputs.modified_files }}"; do for file in "${{ steps.changed-files.outputs.modified_files }}"; do
echo $file echo $file
@ -34,12 +28,10 @@ jobs:
run: | run: |
echo "Your README.md has been modified ${{ steps.changed-files.outputs.modified_files }}." echo "Your README.md has been modified ${{ steps.changed-files.outputs.modified_files }}."
- name: Run changed-files with comma separator - name: Run changed-files with comma separator
if: github.event_name == 'pull_request'
id: changed-files-comma id: changed-files-comma
uses: ./ uses: ./
with: with:
separator: "," separator: ","
- name: Show output - name: Show output
if: github.event_name == 'pull_request'
run: | run: |
echo "${{ toJSON(steps.changed-files-comma.outputs) }}" echo "${{ toJSON(steps.changed-files-comma.outputs) }}"