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

Using yarn over npx results in much more verbose error logs #25

Open
lieberlois opened this issue Jul 8, 2021 · 1 comment
Open

Using yarn over npx results in much more verbose error logs #25

lieberlois opened this issue Jul 8, 2021 · 1 comment

Comments

@lieberlois
Copy link
Contributor

lieberlois commented Jul 8, 2021

When using devcmd with invalid arguments with yarn, for example yarn devcmd, the error log looks something like this:

yarn run v1.22.10
$ cd dev_cmds && yarn devcmd
$ /home/luis/dev/devcmd/dev_cmds/node_modules/.bin/devcmd
devcmd v0.0.8
No script specified.
Command failed: node -e require('devcmd/from-cli').run(...process.argv.slice(1))
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

However, when using npx, the error log is much simpler and way easier to read, something like this:

devcmd v0.0.8
No script specified.
@lieberlois lieberlois changed the title Yar Using yarn over npx results in much more verbose error logs Jul 8, 2021
@lieberlois
Copy link
Contributor Author

lieberlois commented Jul 15, 2021

The amount of yarn error messages depends on the amount of yarn command nestings.
When running yarn devcmd in the root of the repository, the script cd dev_cmds && yarn devcmd is executed, which produces 2 error messages. However, executing (cd packages/devcmd && yarn devcmd) only produces one error message.

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

No branches or pull requests

1 participant