File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -47,12 +47,22 @@ inputs:
47
47
runs :
48
48
using : composite
49
49
steps :
50
+ # Both pnpm and setup-node expect paths relative to checked-out repo. But we
51
+ # want to use package.json and .nvmrc from action repo. So, we'll provide
52
+ # them a path relative to GITHUB_WORKSPACE
53
+ # See https://github.com/actions/setup-node/issues/852
54
+ - id : action_relative_path
55
+ run : |
56
+ action_path=$(node -p 'require("path").relative(process.env.GITHUB_WORKSPACE, "${{ github.action_path }}")')
57
+ echo "action_path=${action_path}" >> "$GITHUB_OUTPUT"
58
+ shell : bash
59
+
50
60
- uses : pnpm/action-setup@v2
51
61
with :
52
- version : 7
62
+ package_json_file : ${{ steps.action_relative_path.outputs.action_path }}/package.json
53
63
- uses : actions/setup-node@v3
54
64
with :
55
- node-version-file : " . nvmrc"
65
+ node-version-file : ${{ steps.action_relative_path.outputs.action_path }}/. nvmrc
56
66
- name : Set up action
57
67
run : |
58
68
echo "::group::Set up action"
You can’t perform that action at this time.
0 commit comments