Skip to content

Commit

Permalink
Force testing
Browse files Browse the repository at this point in the history
Signed-off-by: Jose Luis Rivero <[email protected]>
  • Loading branch information
j-rivero committed Oct 9, 2023
1 parent 9f9a731 commit fce4fb4
Showing 1 changed file with 2 additions and 17 deletions.
19 changes: 2 additions & 17 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: CI

# base_ref / head_reaf are only available in PRs
on: [pull_request]
on: [pull_request, push]

jobs:
dsl_ci:
Expand All @@ -12,24 +12,9 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Idenfify files changed in this PR
id: files
run: |
git fetch origin ${{ github.ref }}
git diff --name-only origin/${{ github.base_ref }}...FETCH_HEAD
echo "changed-files=$(git diff --name-only origin/${{ github.base_ref }}...FETCH_HEAD| tr '\n' ' ')" >> $GITHUB_OUTPUT
- name: Run testing on changed config files
id: dsl_check
run: |
for changed_file in ${{ steps.files.outputs.changed-files }}; do
if [[ ${changed_file} != ${changed_file/dsl\/*} ]]; then
echo "+ Detected at leat one config file: ${changed_file}."
echo "run_job=true" >> $GITHUB_OUTPUT
break
else
echo "run_job=false" >> $GITHUB_OUTPUT
fi
done
run: echo "run_job=true" >> $GITHUB_OUTPUT
- name: Checkout
if: steps.dsl_check.outputs.run_job == 'true'
uses: actions/checkout@v3
Expand Down

0 comments on commit fce4fb4

Please sign in to comment.