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

[feature request] Add support for the bun package manager #25

Closed
eelkevdbos opened this issue Oct 11, 2023 · 7 comments · Fixed by #41
Closed

[feature request] Add support for the bun package manager #25

eelkevdbos opened this issue Oct 11, 2023 · 7 comments · Fixed by #41

Comments

@eelkevdbos
Copy link

Executing bunx update-browserslist-db@latest results in the following error:

update-browserslist-db: No lockfile found. Run "npm install", "yarn install" or "pnpm install"

Bun uses a binary lockfile called bun.lockb and at the time of writing has no built-in method yet to update individual packages.

@ai
Copy link
Member

ai commented Oct 11, 2023

Sure, please send PR.

Just be sure that you are updating all nested dependencies.

@eelkevdbos
Copy link
Author

I'm working on a draft PR and will post back as soon as I have a working setup.

@alec-c4
Copy link

alec-c4 commented Apr 16, 2024

Hey! Any update on this issue? @eelkevdbos

@hbibel
Copy link

hbibel commented Apr 23, 2024

Appears to be blocked by oven-sh/bun#6419

@SrBrahma
Copy link

Bun now supports it! oven-sh/bun#6419 (comment)

@ai
Copy link
Member

ai commented Jun 26, 2024

I need some Bun user to send PR. Here is what you need to do:

  1. Add Bun detection here https://github.com/browserslist/update-db/blob/main/index.js#L41-L57
  2. Add caniuse-lite latest version extraction here https://github.com/browserslist/update-db/blob/main/index.js#L63-L79
  3. Add caniuse-lite update CLI call like this https://github.com/browserslist/update-db/blob/main/index.js#L288-L289
  4. Add tests to text/fixtures and call them from test/index.test.js.

@ai ai mentioned this issue Jun 29, 2024
@ai ai closed this as completed in #41 Jul 1, 2024
@ai ai closed this as completed in 82d24e6 Jul 1, 2024
@ai
Copy link
Member

ai commented Jul 2, 2024

Bun support added with 1.1. Thanks to @pornoiya and @kytta.

Note 2 limits:

  1. You need to have npm to get latest caniuse-lite version.
  2. It will add caniuse-lite to dependencies. bun update adds caniuse-lite to dependencies #42

We created issues in Bun repo to fix these limits.

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 a pull request may close this issue.

5 participants