Skip to content

Commit 909ab47

Browse files
committed
Merge branch 'v0.8.0' of github.com:ZSeven-W/openpencil into v0.8.0
2 parents a77e346 + 8820b5b commit 909ab47

45 files changed

Lines changed: 2407 additions & 1 deletion

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.cargo/config.toml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
[build]
2+
# wasm32 target enabled via rust-toolchain.toml; no override here
3+
4+
[net]
5+
git-fetch-with-cli = true
6+
7+
[term]
8+
verbose = false

.github/workflows/rust-check.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: Rust check (native)
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'Cargo.toml'
7+
- 'Cargo.lock'
8+
- 'crates/**'
9+
- 'rust-toolchain.toml'
10+
- 'rustfmt.toml'
11+
- 'deny.toml'
12+
- '.github/workflows/rust-check.yml'
13+
push:
14+
branches: [main, 'feat/rust-ification']
15+
paths:
16+
- 'Cargo.toml'
17+
- 'Cargo.lock'
18+
- 'crates/**'
19+
- 'rust-toolchain.toml'
20+
21+
jobs:
22+
check:
23+
name: ${{ matrix.os }} / 1.85
24+
runs-on: ${{ matrix.os }}
25+
strategy:
26+
fail-fast: false
27+
matrix:
28+
os: [macos-latest, ubuntu-latest, windows-latest]
29+
steps:
30+
- uses: actions/checkout@v4
31+
with:
32+
submodules: recursive
33+
- uses: dtolnay/rust-toolchain@stable
34+
with:
35+
toolchain: "1.85"
36+
components: rustfmt, clippy
37+
- uses: Swatinem/rust-cache@v2
38+
- run: cargo fmt --all -- --check
39+
- run: cargo build --workspace
40+
- run: cargo test --workspace
41+
- run: cargo clippy --workspace --all-targets -- -D warnings
42+
43+
deny:
44+
name: cargo-deny (native)
45+
runs-on: ubuntu-latest
46+
steps:
47+
- uses: actions/checkout@v4
48+
with:
49+
submodules: recursive
50+
- uses: dtolnay/rust-toolchain@stable
51+
- uses: EmbarkStudios/cargo-deny-action@v2 # auto-updates within v2.x; runner cargo at this stage carries cargo-deny 0.18+ which handles modern transitive manifests (Phase 1 Task 1.8 finding)
52+
with:
53+
command: check
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: WASM bundle check (kickoff §1.2)
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'Cargo.toml'
7+
- 'Cargo.lock'
8+
- 'crates/**'
9+
- 'deny.toml'
10+
- '.github/workflows/wasm-bundle-check.yml'
11+
push:
12+
branches: [main, 'feat/rust-ification']
13+
14+
jobs:
15+
wasm32-check:
16+
name: cargo check --target wasm32-unknown-unknown
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v4
20+
with:
21+
submodules: recursive
22+
- uses: dtolnay/rust-toolchain@stable
23+
with:
24+
toolchain: "1.85"
25+
targets: wasm32-unknown-unknown
26+
- uses: Swatinem/rust-cache@v2
27+
with:
28+
shared-key: wasm32-cache
29+
- name: Forward — bucket A crates compile on wasm32
30+
run: |
31+
cargo check --target wasm32-unknown-unknown \
32+
-p openpencil-shell-web --no-default-features --features web
33+
cargo check --target wasm32-unknown-unknown \
34+
-p pen-types -p pen-core -p pen-engine -p pen-codegen -p pen-figma
35+
36+
wasm32-deny:
37+
name: cargo-deny --target wasm32-unknown-unknown check bans
38+
runs-on: ubuntu-latest
39+
steps:
40+
- uses: actions/checkout@v4
41+
with:
42+
submodules: recursive
43+
- uses: dtolnay/rust-toolchain@stable
44+
with:
45+
targets: wasm32-unknown-unknown
46+
- name: Reverse — blacklisted crates not in wasm bundle
47+
uses: EmbarkStudios/cargo-deny-action@v2 # cargo-deny 0.18+ via the action (Phase 1 Task 1.8 finding)
48+
with:
49+
command: check bans
50+
arguments: --target wasm32-unknown-unknown

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,10 @@ dist-electron/
2929
.omx
3030
.worktrees/
3131
.omx/
32+
33+
# Rust
34+
/target
35+
**/*.rs.bk
36+
Cargo.lock.merge-conflict
37+
/crates/*/target
38+
/vendor/agent/target

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[submodule "packages/agent-native"]
22
path = packages/agent-native
33
url = https://github.com/ZSeven-W/agent.git
4+
[submodule "vendor/agent"]
5+
path = vendor/agent
6+
url = https://github.com/ZSeven-W/agent-rs.git

0 commit comments

Comments
 (0)