diff options
| author | Bobby <[email protected]> | 2022-11-05 10:26:35 -0400 |
|---|---|---|
| committer | Bobby <[email protected]> | 2022-11-05 10:26:35 -0400 |
| commit | 53d051d3ae76e3608be6ddcae81afb61238e1a64 (patch) | |
| tree | 580757f88a6b7818262ecb84c9925cbf35813620 /commit.sh | |
| parent | d0dd22842400e43208356f603814bea425a395be (diff) | |
| download | texty-53d051d3ae76e3608be6ddcae81afb61238e1a64.tar.xz texty-53d051d3ae76e3608be6ddcae81afb61238e1a64.zip | |
fix: Fixed Scripts
Diffstat (limited to 'commit.sh')
| -rwxr-xr-x | commit.sh | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -15,8 +15,6 @@ # This script should return 0 if the commit should proceed or 1 if # the commit should be aborted. -!#/bin/sh - set -e # Get the current branch name @@ -35,7 +33,6 @@ helpFuntion() { exit $1 } - # User Defined Commands commands() { # Add commands here @@ -46,10 +43,10 @@ commands() { python3 -m isort . # Format code - python3 black . + python3 -m black . # Generate Requirements.txt - pipreqs --force . + pipreqs ./ --ignore .venv # Generate Maintainers List python3 scripts/maintainers.py @@ -63,6 +60,7 @@ branch=$(git rev-parse --abbrev-ref HEAD) commit() { # Run User Defined Commands commands + # Check if the branch is the current branch if [ "$branch" == "$(git rev-parse --abbrev-ref HEAD)" ] then @@ -79,6 +77,9 @@ commit() { git commit -m "$msg" git push origin $branch fi + + # exit with success + exit 0 } # Check if the number of arguments is less than 2 |
