感谢你愿意参与 OpenCodex。 本文档定义了最小贡献流程,确保 iOS 客户端、Worker 后端与文档在同一质量基线下演进。
Thank you for contributing to OpenCodex.
This project uses a practical contribution baseline:
- Follow Apache-2.0 licensing requirements.
- Do not commit secrets, certificates, or local config files.
- Run backend tests and iOS build checks before opening a pull request.
- Use
codex/<topic>branch names and clear commit messages. - If runtime access to Codex app-server is unavailable, you can still contribute via tests, UI state logic, and documentation improvements.
- 你同意本仓库采用 Apache License 2.0(Apache 2.0 开源许可证)。
- 你提交的代码为原创,或你有权以 Apache-2.0 方式提交。
- 不要提交密钥、令牌、私有证书、
worker.config.json等本地敏感文件。
最低要求:
- macOS(构建 iOS 端)
- Xcode 16+
- Node.js >= 22(
codex-worker-mvp) - Node.js >= 20(
codex-sessions-tool)
可选要求:
codexCLI(Command Line Interface,命令行接口)- 有效的 Codex app-server 访问权限(用于端到端联调)
没有 app-server 权限也可以贡献:可先跑单元测试与静态检查,提交与 UI/状态机/文档相关的 PR。
- 分支命名:
codex/<topic> - 提交信息建议使用 Conventional Commits(约定式提交)风格:
feat:新功能fix:修复docs:文档test:测试chore:工具或依赖
示例:
feat(ios): add markdown quote block style parity
fix(worker): prevent stale cursor replay on reconnect
cd codex-worker-mvp && npm ci && npm test
cd codex-sessions-tool && npm ci && npm testcd CodexWorkerApp/CodexWorkerApp
xcodebuild -project CodexWorkerApp.xcodeproj \
-scheme CodexWorkerApp \
-destination 'generic/platform=iOS Simulator' \
-skipMacroValidation \
buildswiftformat --lint . --config .swiftformat
swiftlint lint --config .swiftlint.yml请在 PR 描述里至少包含:
- 变更目的与范围
- 风险点与回滚策略(如涉及状态机、同步、缓存)
- 自测结果(命令 + 结果)
- UI 改动请附截图或录屏
- 优先保证现有 API(Application Programming Interface,应用程序编程接口)兼容。
- 如需破坏性变更,请在 PR 标题标注
BREAKING CHANGE,并更新CHANGELOG.md。
安全漏洞请不要公开提 issue,参考 SECURITY.md。