File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # VCS / CI metadata
2+ .git
3+ .github
4+
5+ # Local dependencies and build outputs
6+ node_modules
7+ target
8+ .pnpm-store
9+ .pnpm-debug.log *
10+
11+ # OS noise
12+ .DS_Store
13+
14+ # Submodule checkout is not needed in Docker build context
15+ packages /opencode
16+ packages /opencode /**
Original file line number Diff line number Diff line change 1616 steps :
1717 - uses : actions/checkout@v6
1818
19+ - name : Initialize opencode submodule
20+ run : |
21+ git submodule sync --recursive
22+ git -c url."https://github.com/".insteadOf=git@github.com: submodule update --init --recursive packages/opencode
23+ git submodule status --recursive
24+
1925 - name : Install Rust
2026 uses : dtolnay/rust-toolchain@master
2127 with :
Original file line number Diff line number Diff line change 1717 steps :
1818 - uses : actions/checkout@v6
1919
20+ - name : Initialize opencode submodule
21+ run : |
22+ git submodule sync --recursive
23+ git -c url."https://github.com/".insteadOf=git@github.com: submodule update --init --recursive packages/opencode
24+ git submodule status --recursive
25+
2026 - name : Install Rust
2127 uses : dtolnay/rust-toolchain@master
2228 with :
Original file line number Diff line number Diff line change 2626 with :
2727 # If ref is not provided, checkout defaults to the commit that triggered the workflow
2828 ref : ${{ inputs.ref }}
29- # Required for just targets that validate/build/test packages/opencode.
30- submodules : recursive
29+
30+ - name : Initialize opencode submodule
31+ run : |
32+ git submodule sync --recursive
33+ git -c url."https://github.com/".insteadOf=git@github.com: submodule update --init --recursive packages/opencode
34+ git submodule status --recursive
3135
3236 - name : Log version
3337 if : inputs.version != ''
@@ -50,12 +54,24 @@ jobs:
5054 node-version : ' 20'
5155 cache : ' pnpm'
5256
57+ - name : Install Bun
58+ uses : oven-sh/setup-bun@v2
59+
5360 - name : Rust cache
5461 uses : Swatinem/rust-cache@v2
5562
5663 - name : Install Node dependencies
5764 run : pnpm install --frozen-lockfile --ignore-scripts
5865
66+ - name : Lint opencode packages
67+ run : just lint-opencode
68+
69+ - name : Build opencode packages
70+ run : just build-opencode
71+
72+ - name : Lint opencode broker
73+ run : just lint-opencode-broker
74+
5975 - name : Check formatting
6076 run : cargo fmt --all -- --check
6177
Original file line number Diff line number Diff line change 7070 steps :
7171 - uses : actions/checkout@v6
7272
73+ - name : Initialize opencode submodule
74+ run : |
75+ git submodule sync --recursive
76+ git -c url."https://github.com/".insteadOf=git@github.com: submodule update --init --recursive packages/opencode
77+ git submodule status --recursive
78+
7379 - name : Install Rust
7480 uses : dtolnay/rust-toolchain@master
7581 with :
@@ -88,12 +94,24 @@ jobs:
8894 node-version : ' 20'
8995 cache : ' pnpm'
9096
97+ - name : Install Bun
98+ uses : oven-sh/setup-bun@v2
99+
91100 - name : Rust cache
92101 uses : Swatinem/rust-cache@v2
93102
94103 - name : Install Node dependencies
95104 run : pnpm install --frozen-lockfile --ignore-scripts
96105
106+ - name : Lint opencode packages
107+ run : just lint-opencode
108+
109+ - name : Build opencode packages
110+ run : just build-opencode
111+
112+ - name : Lint opencode broker
113+ run : just lint-opencode-broker
114+
97115 - name : Clippy
98116 run : cargo clippy --all-targets --all-features -- -D warnings
99117
Original file line number Diff line number Diff line change 1818 with :
1919 token : ${{ secrets.GITHUB_TOKEN }}
2020
21+ - name : Initialize opencode submodule
22+ run : |
23+ git submodule sync --recursive
24+ git -c url."https://github.com/".insteadOf=git@github.com: submodule update --init --recursive packages/opencode
25+ git submodule status --recursive
26+
2127 - name : Configure Git
2228 run : |
2329 git config user.name "github-actions[bot]"
3743 exit 0
3844 fi
3945
40- git add packages/core/src/docker/Dockerfile
46+ git add packages/core/src/docker/Dockerfile packages/opencode
4147 git commit -m "chore: update opencode commit"
4248 git push
Original file line number Diff line number Diff line change @@ -32,8 +32,15 @@ git clone https://github.com/pRizz/opencode-cloud.git
3232git clone https://gitea.com/pRizz/opencode-cloud.git
3333cd opencode-cloud
3434
35- # Install dependencies
36- pnpm install
35+ # Initialize submodule checkout
36+ git submodule sync --recursive
37+ git submodule update --init --recursive packages/opencode
38+
39+ # Bun is required for packages/opencode checks/builds
40+ bun --version
41+
42+ # One-time setup (hooks + deps + submodule bootstrap)
43+ just setup
3744
3845# Build everything
3946just build
Original file line number Diff line number Diff line change @@ -161,6 +161,8 @@ git clone https://github.com/pRizz/opencode-cloud.git
161161# Gitea (mirror)
162162git clone https://gitea.com/pRizz/opencode-cloud.git
163163cd opencode-cloud
164+ git submodule sync --recursive
165+ git submodule update --init --recursive packages/opencode
164166cargo install --path packages/cli-rust
165167```
166168
@@ -173,6 +175,13 @@ git clone https://github.com/pRizz/opencode-cloud.git
173175# Gitea (mirror)
174176git clone https://gitea.com/pRizz/opencode-cloud.git
175177cd opencode-cloud
178+ git submodule sync --recursive
179+ git submodule update --init --recursive packages/opencode
180+
181+ # Bun is required for packages/opencode checks/builds
182+ bun --version
183+
184+ just setup
176185just build
177186cargo run -p opencode-cloud -- --version
178187```
@@ -401,11 +410,11 @@ Data (PID files, etc.) is stored at:
401410## Development
402411
403412```bash
404- # Install dependencies
405- pnpm install
413+ # Bun is required for packages/opencode checks/builds
414+ bun --version
406415
407- # Configure git hooks (once after cloning )
408- git config core.hooksPath .githooks
416+ # One-time setup ( hooks + deps + submodule bootstrap )
417+ just setup
409418
410419# Build everything
411420just build
Original file line number Diff line number Diff line change 1010# Setup development environment (run once after cloning)
1111setup :
1212 git config core.hooksPath .githooks
13+ git submodule sync --recursive
14+ git -c url." https://github.com/" .insteadOf=git@github.com: submodule update --init --recursive packages/ opencode
15+ @ command -v bun >/ dev/ null 2 >&1 || (echo " Error: bun is required for packages/opencode checks/builds. Install from https://bun.sh and rerun just setup." && exit 1 )
16+ bun install --cwd packages/ opencode --frozen-lockfile
1317 pnpm install
1418 @ echo " ✓ Development environment ready!"
1519
@@ -111,6 +115,10 @@ check-opencode-submodule-drift:
111115update-opencode-commit :
112116 ./ scripts/ update-opencode-commit.sh
113117
118+ # Format opencode-broker Rust crate
119+ fmt-opencode-broker : opencode-submodule-check
120+ cargo fmt --manifest-path packages/ opencode/ packages/ opencode-broker/ Cargo.toml --all
121+
114122# --- Docker Sandbox Image ---
115123
116124# Build Docker sandbox image with BuildKit caching (amd64 only, for local dev)
@@ -233,7 +241,7 @@ pre-commit-full: fmt lint build test-all-fast build-docker
233241 @ echo " ✓ Full pre-commit checks passed (including Docker build)"
234242
235243# Format everything
236- fmt :
244+ fmt : fmt-opencode-broker
237245 cargo fmt --all
238246 pnpm -r format
239247
Original file line number Diff line number Diff line change @@ -161,6 +161,8 @@ git clone https://github.com/pRizz/opencode-cloud.git
161161# Gitea (mirror)
162162git clone https://gitea.com/pRizz/opencode-cloud.git
163163cd opencode-cloud
164+ git submodule sync --recursive
165+ git submodule update --init --recursive packages/opencode
164166cargo install --path packages/cli-rust
165167```
166168
@@ -173,6 +175,13 @@ git clone https://github.com/pRizz/opencode-cloud.git
173175# Gitea (mirror)
174176git clone https://gitea.com/pRizz/opencode-cloud.git
175177cd opencode-cloud
178+ git submodule sync --recursive
179+ git submodule update --init --recursive packages/opencode
180+
181+ # Bun is required for packages/opencode checks/builds
182+ bun --version
183+
184+ just setup
176185just build
177186cargo run -p opencode-cloud -- --version
178187```
@@ -401,11 +410,11 @@ Data (PID files, etc.) is stored at:
401410## Development
402411
403412```bash
404- # Install dependencies
405- pnpm install
413+ # Bun is required for packages/opencode checks/builds
414+ bun --version
406415
407- # Configure git hooks (once after cloning )
408- git config core.hooksPath .githooks
416+ # One-time setup ( hooks + deps + submodule bootstrap )
417+ just setup
409418
410419# Build everything
411420just build
You can’t perform that action at this time.
0 commit comments