Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
betty-python
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Global Dynamic Exposure
Betty
betty-python
Commits
efcd1341
Commit
efcd1341
authored
Dec 14, 2020
by
Felix Delattre
Browse files
Options
Downloads
Patches
Plain Diff
Reviewed wording for pre-commit hook
parent
006428a1
No related branches found
No related tags found
1 merge request
!6
Review wording for pre-commit hook.
Pipeline
#17356
passed
Dec 22, 2020
Stage: test
Changes
1
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+4
-11
4 additions, 11 deletions
README.md
with
4 additions
and
11 deletions
README.md
+
4
−
11
View file @
efcd1341
...
...
@@ -27,21 +27,14 @@ Run `make check` for checking code format and `make black` for auto-formatting o
## Auto-run checks
Add a
`pre-commit`
hook to git to avoid forgetting style checks before committing to git.
Copy the sample inside the git directory of the project
:
If you want to be reminded early if continuous integration might trigger an error, you can add
a
`pre-commit`
hook to git. To do so, please run this command in the main project directory
:
```
cp
.git/hooks/pre-commit
.sample
.git/hooks/pre-commit
echo "#!/bin/sh\nmake check" >
.git/hooks/pre-commit
&& chmod +x
.git/hooks/pre-commit
```
and add the following content:
```
#!/bin/sh
make check
```
If you want to commit without auto-execution of the pre-commit hook do:
If you want to commit without automatically executing the pre-commit hook, call:
```
git commit --no-verify
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment