-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Added pre-commit and pre-push hooks to ensure proper ci.
Signed-off-by: Jan Willems <[email protected]>
- Loading branch information
Showing
5 changed files
with
45 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
if !(command cargo-make >/dev/null 2>&1); then # Check if cargo-make is installed | ||
echo Attempting to run cargo-make as part of the pre-push hook but it\'s not installed. | ||
echo Please install it by running the following command: | ||
echo | ||
echo " cargo install --force cargo-make" | ||
echo | ||
echo If you don\'t want to run cargo-make as part of the pre-push hook, you can run | ||
echo the following command instead of git push: | ||
echo | ||
echo " git push --no-verify" | ||
exit 1 | ||
fi | ||
|
||
cargo make ci |
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,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
if !(command cargo-make >/dev/null 2>&1); then # Check if cargo-make is installed | ||
echo Attempting to run cargo-make as part of the pre-push hook but it\'s not installed. | ||
echo Please install it by running the following command: | ||
echo | ||
echo " cargo install --force cargo-make" | ||
echo | ||
echo If you don\'t want to run cargo-make as part of the pre-push hook, you can run | ||
echo the following command instead of git push: | ||
echo | ||
echo " git push --no-verify" | ||
exit 1 | ||
fi | ||
|
||
cargo make ci |
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,6 +1,7 @@ | ||
name: brt | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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