zsh:autoload:glog,gstash: Drop trailing \n on copy

This commit is contained in:
2021-05-16 00:48:24 +02:00
parent 8af0b5c79a
commit 44ef15d8ab
2 changed files with 2 additions and 2 deletions

View File

@@ -67,7 +67,7 @@ fzf_preview[stat]="$fzf_preview[construct] { $REPLY }"
# Put the commit hash into the clipboard # Put the commit hash into the clipboard
# (If no known clipboard tool is available, just print it) # (If no known clipboard tool is available, just print it)
local fzf_copy_command="$fzf_preview[construct] echo \"\$out\"" local fzf_copy_command="$fzf_preview[construct] echo -n \"\$out\""
if [[ $OSTYPE =~ darwin ]] && command -v pbcopy &>/dev/null; then if [[ $OSTYPE =~ darwin ]] && command -v pbcopy &>/dev/null; then
fzf_copy_command+=" | pbcopy" fzf_copy_command+=" | pbcopy"
elif command -v xclip &>/dev/null; then elif command -v xclip &>/dev/null; then

View File

@@ -67,7 +67,7 @@ fzf_preview[stat]="$fzf_preview[construct] { $REPLY }"
# Put the commit hash into the clipboard # Put the commit hash into the clipboard
# (If no known clipboard tool is available, just print it) # (If no known clipboard tool is available, just print it)
local fzf_copy_command="$fzf_preview[construct] echo \"\$out\"" local fzf_copy_command="$fzf_preview[construct] echo -n \"\$out\""
if [[ $OSTYPE =~ darwin ]] && command -v pbcopy &>/dev/null; then if [[ $OSTYPE =~ darwin ]] && command -v pbcopy &>/dev/null; then
fzf_copy_command+=" | pbcopy" fzf_copy_command+=" | pbcopy"
elif command -v xclip &>/dev/null; then elif command -v xclip &>/dev/null; then