Skip to content

Renamed network to method across 17 files. - #23

Open
opencode-agent[bot] wants to merge 1 commit into
mainfrom
opencode/schedule-316ff5-20260716081310
Open

Renamed network to method across 17 files.#23
opencode-agent[bot] wants to merge 1 commit into
mainfrom
opencode/schedule-316ff5-20260716081310

Conversation

@opencode-agent

Copy link
Copy Markdown
Contributor

All changes are complete and verified. Here's a summary of what was modified:

Schema changes (Zod) — networkmethod rename:

  • src/schema/transport/transport.ts — changed discriminator from "network" to "method"
  • src/schema/transport/raw/raw.tsnetwork:method: in rawStream and tcpStream
  • src/schema/transport/mkcp/mkcp.tsnetwork:method:
  • src/schema/transport/websocket/websocket.tsnetwork:method:
  • src/schema/transport/grpc/grpc.tsnetwork:method:
  • src/schema/transport/hysteria/hysteria.tsnetwork:method:
  • src/schema/transport/httpupgrade/httpupgrade.tsnetwork:method:
  • src/schema/transport/xhttp/xhttp.tsnetwork:method: in xhttpStream, splithttpStream, and download settings

Markdown fragments:

  • src/schema/transport/methodField.md — new file (renamed from networkField.md) with content unchanged
  • src/schema/transport/networkField.md — deleted
  • src/schema/env/env.md — updated to match new upstream docs (added warnings about pre-load variables, tip about multiple config files, and structured field description)

Link schema (interpreter):

  • src/link/streamSettings.ts — writes/reads ss.method instead of ss.network
  • src/link/trojan.ts — fixed hardcoded network: "tcp" fallback to method: "tcp"

Tests:

  • All .network assertions updated to .method across hysteria2.test.ts, shadowsocks.test.ts, trojan.test.ts, vmess.test.ts

All 120 link tests pass. The only pre-existing failure (schema.test.ts requires dist/ build output) is unrelated.

Triggered by scheduled workflow

New%20session%20-%202026-07-16T08%3A13%3A09.872Z
opencode session  |  github run

@github-actions

Copy link
Copy Markdown

Size Change: +1.52 kB (+0.46%)

Total Size: 333 kB

📦 View Changed
Filename Size Change
dist/full/index.js 73.7 kB +395 B (+0.54%)
dist/full/schema.json 77.8 kB +369 B (+0.48%)
dist/index.js 7.69 kB -1 B (-0.01%)
dist/link/socks.js 702 B +1 B (+0.14%)
dist/link/trojan.js 689 B -1 B (-0.14%)
dist/link/vmess.js 1.62 kB -1 B (-0.06%)
dist/protocolUtils-BfFpFAEI.js 3.21 kB +3.21 kB (new file) 🆕
dist/protocolUtils-CS11qpS7.js 0 B -3.21 kB (removed) 🏆
dist/schema.json 10.6 kB +1 B (+0.01%)
dist/with-docs/index.js 71.7 kB +388 B (+0.54%)
dist/with-docs/schema.json 76.1 kB +364 B (+0.48%)
ℹ️ View Unchanged
Filename Size
dist/base-DKPCIQtF.js 1.67 kB
dist/link/hysteria2.js 937 B
dist/link/index.js 603 B
dist/link/shadowsocks.js 1.27 kB
dist/link/vless.js 593 B
dist/link/wireguard.js 1.14 kB
dist/linkMap-B5frwCZL.js 2.69 kB

compressed-size-action

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.

0 participants