File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,12 +4,12 @@ git hooks.
44It does a few checks on source codes to ensure compliance with some general
55CCDC coding standard.
66
7- The commit will be flagged if it includes text files with:
7+ The commit will be flagged if it includes certain text files with:
88
9- * File name that does meet Windows filename requirement
9+ * File name that can cause errors on Windows
1010* CRLF line endings
1111* NO NOT MERGE or DO NOT COMMIT
12- * Trailing whitespaces
12+ * Trailing whitespace
1313* Tabs
1414* Missing terminating newline for certain files
1515* Certain C++ #include patterns and std::exception
@@ -23,14 +23,21 @@ The commit will be flagged if it includes text files with:
2323` ` `
2424
2525## Scenarios
26- ### Check files
26+ ### Check files in pull request for merge to main
2727` ` ` yaml
28+ name : Check pull request files
29+ on :
30+ pull_request
31+ branches : [ main ]
32+ jobs :
33+ Pull-request-files-check :
34+ runs-on : ubuntu-latest
35+ steps :
2836 - uses : actions/checkout@v2
2937 with :
3038 ref : ${{ github.head_ref }}
3139 fetch-depth : 0
32- - id : check_files
33- uses : ccdc-opensource/commit-hooks@v1
40+ - uses : ccdc-opensource/commit-hooks@v1
3441` ` `
3542
3643# commit-hooks
You can’t perform that action at this time.
0 commit comments