mirror of
https://github.com/dcarrillo/prezto.git
synced 2025-07-01 20:59:26 +00:00
git: Optimize scripts for git helper functions
Optimize git internal calls and adjustment git helper functions to use more idiomatic Zsh conventions avoiding external calls.
This commit is contained in:
committed by
Indrajit Raychaudhuri
parent
efebe3efec
commit
a3643f124e
@ -15,7 +15,7 @@ fi
|
||||
local stashed
|
||||
|
||||
if [[ -f "$(git-dir)/refs/stash" ]]; then
|
||||
stashed="$(command git stash list 2> /dev/null | wc -l | awk '{print $1}')"
|
||||
stashed=${#${(f)"$(command git stash list 2> /dev/null)"}}
|
||||
if (( $stashed > 0 )); then
|
||||
if read -q "?Clear $stashed stashed state(s) [y/N]? "; then
|
||||
command git stash clear
|
||||
|
Reference in New Issue
Block a user