withastro / action

A GitHub Action that deploys your Astro project to GitHub Pages
Other
153 stars 34 forks source link

Actions fails with there are multiple locks files, even if path is set #30

Closed sma closed 9 months ago

sma commented 10 months ago

I think, the Check lockfiles step should respect the path.

I've a repo that contains multiple package-lock.json files which causes this failure:

elif [ $(find "." -name "package-lock.json") ]; then 
/var/run/act/workflow/2-composite-0.sh: line 17: [: ./package-lock.json: binary operator expected

The $() variable contains multiple lines and this is something the [ doesn't like.

Using $(find ${{ inputs.path }} -name "package-lock.json") should do the trick.

natemoo-re commented 10 months ago

I'm curious if https://github.com/withastro/action/pull/31 addresses this issue?

natemoo-re commented 9 months ago

I believe this has been addressed in v1.0.4 and is now supported on the v1 tag, but please open a new issue if that's not the case.