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

Unzip the Bun binary only #29

Merged
merged 3 commits into from
Dec 28, 2024
Merged

Unzip the Bun binary only #29

merged 3 commits into from
Dec 28, 2024

Conversation

crbelaus
Copy link
Owner

@crbelaus crbelaus commented Dec 25, 2024

It looks like some versions of Bun contain multiple directories in the Zip archive. For example, this is the output when extracting the Bun 1.1.42 on MacOS archive:

~/Documents unzip ./bun-darwin-aarch64.zip
Archive:  bun-darwin-aarch64.zip
   creating: bun-darwin-aarch64/
  inflating: bun-darwin-aarch64/bun
   creating: __MACOSX/
   creating: __MACOSX/bun-darwin-aarch64/
  inflating: __MACOSX/bun-darwin-aarch64/._bun

This pull request extracts the bun binary only and discards the rest of the Zip archive contents, which we don't need.

@crbelaus crbelaus changed the title Unzip the un binary only Unzip the Bun binary only Dec 25, 2024
@crbelaus crbelaus force-pushed the unzip-bun-binary-only branch 2 times, most recently from 829d60d to 53e7bab Compare December 25, 2024 10:19
@crbelaus crbelaus self-assigned this Dec 25, 2024
@crbelaus crbelaus force-pushed the unzip-bun-binary-only branch from 53e7bab to 8da52e7 Compare December 25, 2024 10:25
Some versions of Bun (such as 1.1.42) contain more files in the zip
archive. We are just interested in the bun binary.
@crbelaus crbelaus force-pushed the unzip-bun-binary-only branch from 8da52e7 to 3ca2cc3 Compare December 25, 2024 10:28
@gianpispi
Copy link

works, and code looks solid

@bjufre
Copy link

bjufre commented Dec 26, 2024

@crbelaus I tried this as well and it seems to be working, code looks good too 💪

@crbelaus crbelaus merged commit b74908b into main Dec 28, 2024
6 checks passed
@crbelaus crbelaus deleted the unzip-bun-binary-only branch December 28, 2024 10:17
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.

3 participants