-
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.
refactor: moving test script to main script.
- Loading branch information
Showing
2 changed files
with
39 additions
and
3 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 |
---|---|---|
@@ -1,4 +1,32 @@ | ||
#!/bin/bash | ||
|
||
# Author : Eshan Roy <eshan@snigdhaos.org> | ||
# Author URI : https://eshanized.github.io/ | ||
# Author : Eshan Roy | ||
# URI : https://eshanized.github.io | ||
|
||
# NOTE: If you are on Snigdha OS, | ||
# you can install commitizen-go with `sudo pacman -S commitizen-go` | ||
# or `s commitizen-go`. Else you need to install `yay` or `yay-bin` | ||
# to install commitizen. I have written this script only for *Arch Linux. | ||
|
||
# Function to check if Commitizen is installed | ||
check_commitizen() { | ||
if ! pacman -Qq commitizen-go &> /dev/null; then | ||
echo "Commitizen is not installed. Please install it using 'yay -S commitizen-go'." >&2 | ||
exit 1 | ||
fi | ||
} | ||
|
||
# Function to stage, commit, and push changes | ||
push_to_github() { | ||
git add . | ||
git cz | ||
git push origin master | ||
} | ||
|
||
# Main Function | ||
main() { | ||
check_commitizen | ||
push_to_github | ||
} | ||
|
||
main |
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