-
Notifications
You must be signed in to change notification settings - Fork 149
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs(README): update pre-receive docs
- Loading branch information
jguerreiro
committed
Oct 12, 2021
1 parent
fb9d8ff
commit 2bcccf2
Showing
4 changed files
with
33 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/sh | ||
# ggshield as a pre-commit hook | ||
# Move `pre-receive.sample` to `.git/hooks/pre-receive` | ||
# Do not forget to `chmod +x .git/hooks/pre-receive` | ||
# either set an environment variable machine wide `GITGUARDIAN_API_KEY` | ||
# or uncomment and insert your key in the following line | ||
# if you use more than 2 push options, be sure to export them to the container | ||
|
||
#export GITGUARDIAN_API_KEY=<INSERT YOUR KEY> | ||
|
||
set -x | ||
docker run -i --rm -v $(pwd):/data ggshield -e GIT_PUSH_OPTION_COUNT -e GIT_PUSH_OPTION_0 -e GIT_PUSH_OPTION_1 -e GITGUARDIAN_API_KEY gitguardian/ggshield:latest ggshield scan pre-receive |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,15 @@ | ||
#!/bin/sh | ||
# ggshield as a pre-commit hook | ||
# Move `pre-receive.sample` to `.git/hooks/pre-receive` | ||
# Prequirements: | ||
# python >= 3.6, pip | ||
# Installation instructions: | ||
# Run: pip install ggshield | ||
# Move `pre-receive-python.sample` to `.git/hooks/pre-receive` | ||
# Do not forget to `chmod +x .git/hooks/pre-receive` | ||
# either set an environment variable machine wide `GITGUARDIAN_API_KEY` | ||
# or uncomment and insert your key in the following line | ||
# if you use more than 2 push options, be sure to export them to the container | ||
|
||
#export GITGUARDIAN_API_KEY=<INSERT YOUR KEY> | ||
|
||
set -x | ||
docker run -i --rm -v $(pwd):/data ggshield -e GIT_PUSH_OPTION_COUNT -e GIT_PUSH_OPTION_0 -e GIT_PUSH_OPTION_1 -e GITGUARDIAN_API_KEY gitguardian/ggshield:latest ggshield scan pre-receive | ||
set -e | ||
ggshield scan pre-receive |