Skip to content

Commit

Permalink
fix: do not fallback to latest if pnpm version is missing
Browse files Browse the repository at this point in the history
  • Loading branch information
meeroslav committed Sep 6, 2023
1 parent 38a347b commit 294980c
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/nx-cloud-agents.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,13 @@ jobs:

# Install pnpm with exact version provided by consumer or fallback to latest
- name: Install PNPM
if: steps.package_manager.outputs.name == 'pnpm'
if: steps.package_manager.outputs.name == 'pnpm' && inputs.pnpm-version != ''
uses: pnpm/action-setup@v2
with:
version: ${{ inputs.pnpm-version || 'latest' }}
version: ${{ inputs.pnpm-version }}
- name: Install PNPM
if: steps.package_manager.outputs.name == 'pnpm' && inputs.pnpm-version == ''
uses: pnpm/action-setup@v2

- name: Print node/npm/yarn versions
id: versions
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/nx-cloud-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,13 @@ jobs:

# Install pnpm with exact version provided by consumer or fallback to latest
- name: Install PNPM
if: steps.package_manager.outputs.name == 'pnpm'
if: steps.package_manager.outputs.name == 'pnpm' && inputs.pnpm-version != ''
uses: pnpm/action-setup@v2
with:
version: ${{ inputs.pnpm-version || 'latest' }}
version: ${{ inputs.pnpm-version }}
- name: Install PNPM
if: steps.package_manager.outputs.name == 'pnpm' && inputs.pnpm-version == ''
uses: pnpm/action-setup@v2

- name: Print node/npm/yarn versions
id: versions
Expand Down
3 changes: 2 additions & 1 deletion integration-tests/pnpm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,6 @@
"ts-jest": "29.1.0",
"ts-node": "10.9.1",
"typescript": "4.9.5"
}
},
"packageManager": "[email protected]"
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"private": true,
"version": "0.13.0",
"version": "0.13.1",
"description": "This package.json is here purely to control the version of the Action, in combination with https://github.com/JamesHenry/publish-shell-action"
}

0 comments on commit 294980c

Please sign in to comment.