-
-
Notifications
You must be signed in to change notification settings - Fork 316
chore: Use Bun for package management #1649
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
base: main
Are you sure you want to change the base?
Changes from all commits
e616cd4
1789e90
1cab591
52d3e72
6c8807b
a26be51
83f8991
5f8ded6
16eda38
1e81f7c
6b8986b
0a69f56
9caa8a1
e2a89ae
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||
---|---|---|---|---|
|
@@ -6,6 +6,7 @@ | |||
# Mark lock files as generated to avoid diffing | ||||
pnpm-lock.yaml linguist-generated | ||||
package-lock.json linguist-generated | ||||
bun.lock linguist-generated | ||||
bun.lockb linguist-generated | ||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There's still a test fixture containing a binary lockfile, I'll try and remove this one when I update E2E tests to use bun. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Okay |
||||
yarn.lock linguist-generated | ||||
aklinker1 marked this conversation as resolved.
Show resolved
Hide resolved
|
||||
|
||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,27 @@ | ||
name: Basic Setup | ||
description: Install PNPM, Node, and dependencies | ||
description: Install Bun and Dependencies | ||
|
||
inputs: | ||
install: | ||
default: 'true' | ||
type: boolean | ||
description: Whether or not to run 'pnpm install' | ||
description: Whether or not to run 'bun install' | ||
|
||
installArgs: | ||
default: '' | ||
type: string | ||
description: Additional args to append to "pnpm install" | ||
description: Additional args to append to "bun install" | ||
|
||
runs: | ||
using: composite | ||
|
||
steps: | ||
- name: 🛠️ Setup PNPM | ||
uses: pnpm/action-setup@v4 | ||
|
||
- name: 🛠️ Setup NodeJS | ||
uses: actions/setup-node@v4 | ||
- name: 🛠️ Setup Bun | ||
uses: oven-sh/setup-bun@v2 | ||
with: | ||
node-version: 18 | ||
cache: pnpm | ||
bun-version-file: package.json | ||
|
||
- name: 📦 Install Dependencies | ||
if: ${{ inputs.install == 'true' }} | ||
shell: bash | ||
run: pnpm install ${{ inputs.installArgs }} | ||
run: bun install ${{ inputs.installArgs }} |
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -52,18 +52,18 @@ jobs: | |||||||||
|
||||||||||
- name: Bump and Tag | ||||||||||
run: | | ||||||||||
pnpm tsx scripts/bump-package-version.ts ${{ inputs.package }} | ||||||||||
bun run scripts/bump-package-version.ts ${{ inputs.package }} | ||||||||||
git push | ||||||||||
git push --tags | ||||||||||
|
||||||||||
- name: Publish to NPM | ||||||||||
working-directory: packages/${{ inputs.package }} | ||||||||||
run: | | ||||||||||
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc | ||||||||||
pnpm build | ||||||||||
pnpm publish | ||||||||||
bun run build | ||||||||||
bun publish | ||||||||||
Comment on lines
+63
to
+64
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I recommend using
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. WXT doesn't have provenance right now, so I'll do this in a separate PR. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Ok |
||||||||||
|
||||||||||
- name: Create GitHub release | ||||||||||
run: pnpm tsx scripts/create-github-release.ts ${{ inputs.package }} | ||||||||||
run: bun run scripts/create-github-release.ts ${{ inputs.package }} | ||||||||||
env: | ||||||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -24,11 +24,11 @@ jobs: | |||||||
|
||||||||
- name: Generate Latest Code | ||||||||
working-directory: packages/browser | ||||||||
run: pnpm gen | ||||||||
run: bun run gen | ||||||||
|
||||||||
- name: Run Checks | ||||||||
working-directory: packages/browser | ||||||||
run: pnpm check | ||||||||
run: bun run check | ||||||||
|
||||||||
- name: Commit Changes | ||||||||
id: commit | ||||||||
|
@@ -43,4 +43,4 @@ jobs: | |||||||
working-directory: packages/browser | ||||||||
run: | | ||||||||
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc | ||||||||
pnpm publish | ||||||||
bun publish | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
Uh oh!
There was an error while loading. Please reload this page.