Skip to content

Commit

Permalink
use environemnt variable for if
Browse files Browse the repository at this point in the history
  • Loading branch information
LukasFey-GIP committed Nov 3, 2023
1 parent 1f3bfe7 commit 2f7c90e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/build-on-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,16 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh pr diff {{ github.event.pull_request.number }} --name-only | grep '^modules/' | cut -f 2-3 -d/ | sort | uniq | tee changed-modules.txt
echo "CHANGES=$(cat changed-modules.txt | wc -l)" >> "$GITHUB_ENV"
- name: build basic factory
run: |
cd installation
./build.sh build
if: $(cat changed-modules.txt | wc -l) != 0
if: env.CHANGES > 0

- name: build changed modules
run: |
cd modules
for d in $(cat ../changed-modules.txt); do test -d "$d" && ant -Doracle.home=/tmp -f "$d/build.xml"; done
if: $(cat changed-modules.txt | wc -l) != 0
if: env.CHANGES > 0

0 comments on commit 2f7c90e

Please sign in to comment.