oh-graphic-gitcode-pr-creator
OpenHarmony Graphic Gitcode PR Creator
Quick Start
Create a Gitcode PR by following these steps:
- Check git status - Verify modified files
- Commit changes - Add Signed-off-by to commit message
- Push to remote - Push branch to origin
- Create Issue - Create related issue
- Create PR - Use PR template from
.gitcode/PULL_REQUEST_TEMPLATE.zh-CN.md
Workflow
1. Check Git Status
git status
git diff <file>
2. Commit Changes
Get user config and create commit with Signed-off-by:
git config user.name
git config user.email
git add <files>
git commit -m "<message>\n\nSigned-off-by: <name> <<email>>"
3. Push to Remote
git push origin <branch-name>
Note: You need to ask the user for the target branch name before creating the PR. Common options:
master(default for most cases)OpenHarmony-6.1-Release(for 6.1 release branch)
4. Create Issue
Use gitcode_create_issue to create issue with:
- Title: PR title
- Body: Description of changes
5. Create PR
Read PR template from .gitcode/PULL_REQUEST_TEMPLATE.zh-CN.md and fill in:
- Description: Summary of changes
- Issue number: Link to created issue
- Test & Result: Test information
- CodeCheck: Fill all self-check results with "Pass"
- L0新增用例自检结果: Check appropriate box
Use gitcode_create_pull_request with formatted body.
CodeCheck Template
When filling CodeCheck table, ensure all rows have "Pass" in the result column:
| 类型 | 自检项 | 自检结果 |
|---|---|---|
| 多线程 | ... | Pass |
| 内存操作 | ... | Pass |
| 外部输入 | ... | Pass |
| 敏感信息 | ... | Pass |
| 数学运算 | ... | Pass |
| 初始化 | ... | Pass |
| 权限管理 | ... | Pass |
Common Patterns
Test Optimization PRs
For test file optimizations:
- Description: "Optimize <test_file> - remove redundant code and improve coverage"
- CodeCheck: All Pass (test code doesn't typically trigger security checks)
- L0用例: Check "是,有新增L0用例,且完成自检"
Bug Fix PRs
For bug fixes:
- Description: "Fix <bug_description> in "
- Test & Result: Describe test scenario and expected behavior
- CodeCheck: All Pass
Important Notes
- Always use the Chinese PR template for OpenHarmony projects
- Ensure branch name is descriptive
- Link PR to issue for traceability
- Force push with
--forcewhen amending commits
More from openharmonyinsight/openharmony-skills
openharmony-security-review
Use when reviewing OpenHarmony C++ system service code for security vulnerabilities, particularly IPC handlers, multithreaded components, or code handling sensitive user data
77openharmony-cpp
Expert coding guide for OpenHarmony C++ development. Use this skill when writing, refactoring, or reviewing C++ code for OpenHarmony projects. It enforces strict project-specific conventions (naming, formatting, headers) and critical security requirements (input validation, memory safety).
76oh-ut-generator
|
65cpp-core-guidelines-review
Parallel C++ Core Guidelines code review using multiple specialized sub-agents. Use when reviewing C++ code, modules, or files against C++ Core Guidelines to identify violations. Each sub-agent reviews against a specific guideline section (Functions, Classes, Resource Management, etc.) and outputs findings to separate markdown files in the review/ directory, followed by a consolidated summary.
59openharmony-build
This skill should be used when the user asks to "编译 OpenHarmony", "build OpenHarmony", "编译完整代码", "执行编译", "编译 OpenHarmony 代码", "快速编译", "跳过gn编译", "fast-build", "编译测试", "编译测试用例", "build ace_engine_test", "编译 sdk", "编译 SDK", "build sdk", "build SDK", "编译 ohos-sdk", "编译测试列表", "build test list", "按列表编译测试", "编译指定测试", or mentions building the full OpenHarmony system, fast rebuild, test compilation, SDK compilation, or building tests from a target list. Handles complete build process including build execution, success verification, and failure log analysis with primary focus on out/{product}/build.log.
55ohos-chromium-security-review
|
55