fix the pop preview

This commit is contained in:
RingOfStorms (Joshua Bell) 2025-07-11 08:15:13 -05:00
parent 39403225d0
commit 5cddd9fd55

View file

@ -156,7 +156,9 @@ stash() {
pop() { pop() {
local selection local selection
selection=$(git stash list | fzf --prompt="Select stash to pop: " --preview="git stash show -p $(echo {} | awk -F: '{print $1}') | bat --color always --paging=never -l diff") selection=$(git stash list | \
fzf --prompt="Select stash to pop: " \
--preview="git stash show -p \$(echo {} | awk -F: '{print \$1}') | bat --color always --paging=never --style=plain -l diff")
[ -z "$selection" ] && echo "No stash selected." && return 1 [ -z "$selection" ] && echo "No stash selected." && return 1
local stash_ref local stash_ref
stash_ref=$(echo "$selection" | awk -F: '{print $1}') stash_ref=$(echo "$selection" | awk -F: '{print $1}')