mirror of
https://github.com/charmbracelet/gum
synced 2024-06-04 23:02:16 +02:00
Add staged file check for commit example (#269)
* Add staged file check for commit example * fix: stage all confirmation --------- Co-authored-by: Maas Lalani <maas@lalani.dev>
This commit is contained in:
parent
46dee843db
commit
83db83296a
|
@ -10,6 +10,10 @@
|
|||
#
|
||||
# alias gcm='git commit -m "$(gum input)" -m "$(gum write)"'
|
||||
|
||||
if [ -z "$(git status -s -uno | grep -v '^ ' | awk '{print $2}')" ]; then
|
||||
gum confirm "Stage all?" && git add .
|
||||
fi
|
||||
|
||||
TYPE=$(gum choose "fix" "feat" "docs" "style" "refactor" "test" "chore" "revert")
|
||||
SCOPE=$(gum input --placeholder "scope")
|
||||
|
||||
|
|
Loading…
Reference in a new issue