Skip to content

Commit

Permalink
bug: missed triggers still firing (#35)
Browse files Browse the repository at this point in the history
* bug: missed triggers still firing
  • Loading branch information
DerekRoberts authored Aug 29, 2023
1 parent 06f8344 commit 150d093
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,23 +110,23 @@ runs:
# Setup node and cache dir
- uses: actions/setup-node@v3
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
with:
node-version: ${{ inputs.node_version }}
- id: npm-cache-dir
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
shell: bash
run: echo "dir=$(npm config get cache)" >> $GITHUB_OUTPUT
- uses: actions/cache@v3
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
with:
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node-

# Run tests, hopefully generating coverage for SonarCloud
- name: Run Tests
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
shell: bash
run: |
cd ${{ inputs.dir }}
Expand All @@ -136,7 +136,7 @@ runs:

# If sonar_token
- name: SonarCloud Scan
if: inputs.sonar_token && steps.vars.outputs.triggered
if: inputs.sonar_token && steps.vars.outputs.triggered == 'true'
uses: SonarSource/[email protected]
env:
SONAR_TOKEN: ${{ inputs.sonar_token }}
Expand All @@ -149,13 +149,13 @@ runs:

# Fix - Docker takes ownership of files, causing a cleanup fail
- shell: bash
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
id: get_uid
run: |
# User for workstation ownership reset/fix
echo "uid=$(id -u ${USER})" >> $GITHUB_OUTPUT
- uses: peter-murray/reset-workspace-ownership-action@v1
if: steps.vars.outputs.triggered
if: steps.vars.outputs.triggered == 'true'
with:
user_id: ${{ steps.get_uid.outputs.uid }}

Expand Down

0 comments on commit 150d093

Please sign in to comment.