diff options
| author | Bobby <[email protected]> | 2022-11-05 02:12:06 -0400 |
|---|---|---|
| committer | Bobby <[email protected]> | 2022-11-05 02:12:06 -0400 |
| commit | ccad8963ece68a1b598bcce4a41f42b6d8994712 (patch) | |
| tree | 44055648faadb727006f70e1c6b5665cc3d5f7ed /commit.sh | |
| parent | 33d1157611299bda066dbc5ca8cdcee5ed2b84f2 (diff) | |
| download | texty-ccad8963ece68a1b598bcce4a41f42b6d8994712.tar.xz texty-ccad8963ece68a1b598bcce4a41f42b6d8994712.zip | |
feat: Added support for virtual envs
Diffstat (limited to 'commit.sh')
| -rwxr-xr-x | commit.sh | 12 |
1 files changed, 4 insertions, 8 deletions
@@ -40,12 +40,8 @@ commands() { # Example: # echo "Hello World" - # Generate Requirements.txt, delete the old one if it exists - if [ -f requirements.txt ] - then - rm requirements.txt - fi - pip3 freeze > requirements.txt + # Generate Requirements.txt + pipreqs --force . } # Default values for optional arguments @@ -136,13 +132,13 @@ fi if [[ $type =~ ^(feat|fix|docs|style|refactor|perf|test|chore|revert)$ ]] then # If type is valid, run commit function - commit $files "$message" $type $branch + commit "$files" "$message" $type $branch else # If type is invalid, prompt the to use the default type read -p "Invalid type. Do you want to use the default type "feat"? (y/n): " useDefaultType if [[ $useDefaultType =~ ^[Yy]$ ]] || [[ $useDefaultType =~ ^[Yy][Ee][Ss]$ ]] then - commit $files "$message" $type $branch + commit "$files" "$message" $type $branch else echo "Commit aborted" exit 1 |
