Skip to content
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
979e401
feat: add bun compile support for binary distribution
claude Nov 8, 2025
788e10b
feat: improve binary build process and add release workflow
claude Nov 8, 2025
802ea6b
refactor: simplify binary build process using bun --external giget
claude Nov 8, 2025
51b7ee9
Merge remote-tracking branch 'origin/main' into claude/enable-bun-com…
claude Nov 8, 2025
0fe7a9d
chore: add giget to cspell dictionary
claude Nov 8, 2025
7e58278
Merge remote-tracking branch 'origin/main' into claude/enable-bun-com…
cm-dyoshikawa Nov 8, 2025
5e07f39
chore: update .gitignore for Bun compiled binaries
cm-dyoshikawa Nov 8, 2025
e32a19f
chore: streamline Bun binary build process and workflows
cm-dyoshikawa Nov 8, 2025
fc80928
refactor: reorganize CI/E2E workflows for better separation of concerns
cm-dyoshikawa Nov 8, 2025
0e0d1ae
chore: update E2E workflow name to clarify cross-platform testing
cm-dyoshikawa Nov 8, 2025
81f56a9
chore: add dependency installation step to E2E workflow
cm-dyoshikawa Nov 8, 2025
7be4797
chore: skip install scripts in E2E workflow
cm-dyoshikawa Nov 8, 2025
be59d7d
refactor: reorganize GitHub Actions workflows for better separation
cm-dyoshikawa Nov 8, 2025
306bf6d
fix: adjust release workflow permissions to read-only
cm-dyoshikawa Nov 8, 2025
927cbd9
chore: simplify release workflow by using Bun exclusively
cm-dyoshikawa Nov 9, 2025
5170fba
fix: address high-severity security issues in GitHub Actions workflows
cm-dyoshikawa Nov 9, 2025
ff7f4e8
chore: pin Bun version to 1.3.2 in mise.toml for consistency
claude Nov 9, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,8 @@ RUN /home/node/.local/bin/mise trust /workspace && /home/node/.local/bin/mise in
# Install global npm packages
RUN npm i -g opencode-ai @openai/codex opencommit @google/gemini-cli

# Install Bun with smol mode to reduce memory usage
# Enable smol mode in Bun to reduce memory usage
RUN echo 'smol = true' > /home/node/bunfig.toml
RUN curl -fsSL https://bun.sh/install | bash

# Aliases
RUN echo "alias claude=\"claude --dangerously-skip-permissions\"" >> "/home/node/.zshrc"
Expand Down
73 changes: 73 additions & 0 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: E2E Tests

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
build:
name: Build binaries
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v5

- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.2

- name: Build binaries
run: |
mkdir -p dist-bun
# Linux
bun build --compile --target=bun-linux-x64 src/cli/index.ts --outfile dist-bun/rulesync-linux-x64
bun build --compile --target=bun-linux-arm64 src/cli/index.ts --outfile dist-bun/rulesync-linux-arm64
# macOS
bun build --compile --target=bun-darwin-x64 src/cli/index.ts --outfile dist-bun/rulesync-darwin-x64
bun build --compile --target=bun-darwin-arm64 src/cli/index.ts --outfile dist-bun/rulesync-darwin-arm64

- name: Cache binaries
uses: actions/cache/save@v4
with:
path: dist-bun
key: rulesync-binaries-${{ github.sha }}
enableCrossOsArchive: true

e2e:
name: E2E Test (${{ matrix.os }})
runs-on: ${{ matrix.os }}
needs: build
strategy:
matrix:
os: [ubuntu-latest, macos-latest]

steps:
- name: Checkout code
uses: actions/checkout@v5

- name: Restore cached binaries
uses: actions/cache/restore@v4
with:
path: dist-bun
key: rulesync-binaries-${{ github.sha }}
enableCrossOsArchive: true
fail-on-cache-miss: true

- name: Make binary executable
run: |
if [ "${{ matrix.os }}" = "ubuntu-latest" ]; then
chmod +x dist-bun/rulesync-linux-x64
BINARY_PATH=dist-bun/rulesync-linux-x64
else
chmod +x dist-bun/rulesync-darwin-arm64
BINARY_PATH=dist-bun/rulesync-darwin-arm64
fi
echo "BINARY_PATH=$BINARY_PATH" >> $GITHUB_ENV

- name: Test binary version
run: |
${{ env.BINARY_PATH }} --version
44 changes: 43 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:

permissions:
id-token: write # Required for OIDC
contents: read
contents: write # Required for uploading release assets

jobs:
publish:
Expand Down Expand Up @@ -43,3 +43,45 @@ jobs:

- name: Publish to npm
run: pnpm publish

build-binaries:
name: Build and upload binaries
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v5
with:
ref: main

- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: '24'

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10.20.0

- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest

- name: Install dependencies
run: pnpm install

- name: Build binaries
run: |
# Linux
bun build --compile --target=bun-linux-x64 src/cli/index.ts --outfile dist-bun/rulesync-linux-x64
bun build --compile --target=bun-linux-arm64 src/cli/index.ts --outfile dist-bun/rulesync-linux-arm64
# macOS
bun build --compile --target=bun-darwin-x64 src/cli/index.ts --outfile dist-bun/rulesync-darwin-x64
bun build --compile --target=bun-darwin-arm64 src/cli/index.ts --outfile dist-bun/rulesync-darwin-arm64

- name: Upload binary to release
uses: softprops/action-gh-release@v2
with:
files: dist-bun/${{ matrix.artifact }}
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ out
# Nuxt.js build / generate output
.nuxt
dist
dist-bun

# Gatsby files
.cache/
Expand Down Expand Up @@ -259,3 +260,7 @@ repomix-output.xml
**/.geminiignore

modular-mcp.json

# Bun compiled binaries
dist-bun/
*.bun-build
1 change: 1 addition & 0 deletions cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@
"geminicli",
"geminiignore",
"gibo",
"giget",
"GITSTATUS",
"globby",
"gnueabihf",
Expand Down
1 change: 1 addition & 0 deletions mise.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[tools]
bun = "latest"
node = "24"
pnpm = "10.20.0"
python = "3"
Expand Down
Loading