Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quote watch argument #125

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

gagern
Copy link

@gagern gagern commented Mar 5, 2023

I tried following the README:

# Watch the source directory in one terminal, automatically rebuilding when needed
yarn run watch

The yarn run watch failed for me, using node v16.17.1 and yarn 3.4.1:

No matches found: "watch:*"

It works if I run node_modules/.bin/npm-run-all -p 'watch:*' in shell. It also works if I quote the argument. Looks to me like something is trying to expand that glob before invoking the binary. strace shows that the command doesn't get passed to sh -c as a whole. And npm-run-all isn't even executed so the error message is not coming from it. On the plus side, the fact that apparently these commands get executed by code inside node means portability should be no concern, and if single quotes work for me they hopefully work for everyone.

I tried following the README:

https://github.com/jupyter-widgets/widget-ts-cookiecutter/blob/94f9d384331150655c18a08d94307280c32adedd/README.md?plain=1#L94-L95

The `yarn run watch` failed for me, using node v16.17.1 and yarn 3.4.1:

> No matches found: "watch:*"

It works if I run `node_modules/.bin/npm-run-all -p 'watch:*'` in shell. It also works if I quote the argument. Looks to me like something is trying to expand that glob before invoking the binary. `strace` shows that the command doesn't get passed to `sh -c` as a whole. And `npm-run-all` isn't even executed so the error message is not coming from it. On the plus side, the fact that apparently these commands get executed by code inside node means portability should be no concern, and if single quotes work for me they hopefully work for everyone.
@AnthonyAndroulakis
Copy link

AnthonyAndroulakis commented May 24, 2023

I second this - I used node v18.15.0 and yarn 3.5.1. The yarn run watch command failed for me as well, and only worked when I quoted the argument.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants