| ci: add pre-commit script
Co-authored-by: shilinlee<836160610@qq.com>
# message auto-generated for no-merge-commit merge:
!472 merge mf_pre_commit into develop
ci: add pre-commit script
Created-by: shilinlee_com
Commit-by: shilinlee
Merged-by: yrewzjsx
Description: # Pull Request Template
## Description
chore: add pre-commit script and format files
### Tips
本地提交代码前自动格式化:
```
pip install pre-commit
pre-commit install
```
**手动运行脚本,执行增量检查。**
设置对比基线的分支环境变量,**增量**检查你MR检查:
```bash
export TARGET_BRANCH=develop # 默认develop
bash script/ci-pre-commit-pr.sh
```
## Related Issues
<!-- Replace with actual issue numbers. Example: Closes #123, Related to #456 -->
## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Performance optimization
- [ ] Documentation update
- [ ] Other (please describe):_______________
## Testing
<!-- Describe how the changes were tested. Include:
- Unit/integration test coverage
- Manual validation steps
- Links to CI reports (e.g., CIDA) if available
- Note any pending tests
-->
## Checklist
- [x] I have performed a self-review of my own code.
- [ ] I have updated the documentation.
- [ ] I have added tests to prove my changes are effective.
See merge request: Ascend/memfabric_hybrid!472 | 1 个月前 |