diff options
-rwxr-xr-x | .local/bin/yc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/.local/bin/yc b/.local/bin/yc new file mode 100755 index 0000000..c0108cf --- /dev/null +++ b/.local/bin/yc | |||
@@ -0,0 +1,11 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | |||
3 | TYPE=$(gum choose "fix" "feat" "docs" "style" "refactor" "test" "chore" "revert") | ||
4 | SCOPE=$(gum input --placeholder "scope") | ||
5 | |||
6 | test -n "$SCOPE" && SCOPE="($SCOPE)" | ||
7 | |||
8 | SUMMARY=$(gum input --value "$TYPE$SCOPE: " --placeholder "summary of this change") | ||
9 | DESCRIPTION=$(gum write --placeholder "details of this change (<C-d> to finish)") | ||
10 | |||
11 | gum confirm "commit changes?" && yadm commit -m "$SUMMARY" -m "$DESCRIPTION" | ||