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

Add npx-like behavior #157

Open
renejfc opened this issue Mar 3, 2024 · 2 comments · May be fixed by #284
Open

Add npx-like behavior #157

renejfc opened this issue Mar 3, 2024 · 2 comments · May be fixed by #284
Assignees
Labels
feature New feature or request

Comments

@renejfc
Copy link

renejfc commented Mar 3, 2024

I'm submitting this feature request encouraged by @marvinhagemeister on the Discord server.

Context

I was wondering if we could run packages "on the fly" similar to how npx, yarn dlx, pnpm dlx and bunx does.

Behavior

Basically, the expected behavior would be the same or similar as explained in the docs of the previously mentioned commands (npx for reference).

In other words, running the command will first search for the package locally. If it's found, it will run it directly. Otherwise, the command will temporarily fetch the package, run it, and then delete it after use.

Examples

I guess this will be discussed either here, in the pr or by the team but here are a few examples from the top of my head.

  • bunx jsrx @<namespace>/<package>
  • npx jsr:@<namespace>/<package>
  • And honestly that would be it. Feel free to comment more examples.

NOTE: I hope the idea is well conveyed and there wasn't a misunderstanding with the feature, feel free to comment what you think about it or ping me if want to add something to the post.
@littledivy littledivy added the feature New feature or request label Mar 4, 2024
@halvardssm
Copy link
Contributor

I was also thinking the same, that a bin property similar to package.json would be great to have 💪🏻

@andeeplus
Copy link

Hi everybody, looks the pr related to this ticket is in stale, any update on the topic? Thanks a lot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
Status: Needs Plan
Development

Successfully merging a pull request may close this issue.

5 participants