Yarn 2 compatible executable (npx)

See original GitHub issue

When trying to execute the npx tailwind command it fails, that’s why yarn 2 have what’s known as yarn dlx to execute a binary in a temp environment (https://yarnpkg.com/cli/dlx). However, when trying to run the tailwind binary using the new yarn dlx command, the following is prompted:

$ yarn dlx tailwind init
Internal Error: Binary not found (tailwind) for root-workspace-0b6124@workspace:.
    at m (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:24:7171)
    at async Object.t.executeWorkspaceAccessibleBinary (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:24:9551)
    at async u.execute (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:58:123405)
    at async u.validateAndExecute (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:24:40434)
    at async c.run (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:36:533800)
    at async c.runExit (E:\<PROJECT_ROOT>\.yarn\releases\yarn-rc.js:36:533934)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
tlgregcommented, Apr 4, 2020

As per docs, the yarn run command should still work. If there is no script for it in package.json it should match with a local binary. The tailwind command is deprecated though as Adam said above, so it should be: yarn run tailwindcss <command>

1reaction
ConsoleTVscommented, Apr 4, 2020

This can be closed I assume if the provided solutions work then @adamwathan. I will let you close it in case this was not the final solution. Didn’t have time to check it out yet.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Yarn 2 compatible executable (npx) · Issue #1350 - GitHub
When trying to execute the npx tailwind command it fails, that's why yarn 2 have what's known as yarn dlx to execute a...
Read more >
npx | Yarn - Package Manager
Fast, reliable, and secure dependency management.
Read more >
Introducing Yarn 2 ! - DEV Community ‍ ‍
Yarn 2 introduces a new command called yarn dlx (dlx stands for download and execute) which basically does the same thing as npx...
Read more >
npx(1) -- execute npm package binaries
execute npm package binaries. Latest version: 10.2.2, last published: 3 years ago. Start using npx in your project by running `npm i npx`....
Read more >
Introducing npx: an npm package runner | by Kat Marchán
npx is a tool intended to help round out the experience of using ... npx makes it easy to use CLI tools and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found