pnpm / action-setup

Install pnpm package manager
https://github.com/marketplace/actions/setup-pnpm
MIT License
899 stars 87 forks source link

Parse package.json from subfolder #83

Closed some-user123 closed 1 year ago

some-user123 commented 1 year ago

My package.json is not located at top level but in a subfolder at ui/package.json. This is not picked up by this action.

Error: Error: ENOENT: no such file or directory, open '/home/runner/work/$repo/$repo/package.json'

actions/setup-node allows to explicitly define the path, e.g.

with:
  node-version-file: 'ui/package.json'
  cache: pnpm
  cache-dependency-path: ui/pnpm-lock.yaml

It would be nice to have something similar for this action, e.g.

with:
  pnpm-version-file: 'ui/package.json'

Setting the working-directory does not work.

defaults:
  run:
    working-directory: ./ui
KSXGitHub commented 1 year ago

v2.3.0 has been released. You may check if it work properly.