dotfiles

My personal shell configs and stuff
git clone git://git.alex.balgavy.eu/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

commit 20f1aafd2db8f5893a2040bd8ec50460b3ecd371
parent 812f7f34d206dc7853706898142053f1b976ff11
Author: Alex Balgavy <alex@balgavy.eu>
Date:   Thu, 30 Sep 2021 00:37:55 +0200

vim: fix ultisnips sh printf

Diffstat:
Mvim/ultisnips/sh.snippets | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/vim/ultisnips/sh.snippets b/vim/ultisnips/sh.snippets @@ -31,7 +31,7 @@ while [ \$((\$#)) -ne 0 ]; do exit 1 ;; *) # preserve positional arguments - PARAMS="\$PARAMS $(printf '%q' "\$1")" + PARAMS="\$PARAMS \$(printfq "\$1")" shift ;; esac @@ -152,6 +152,6 @@ fi endsnippet snippet printfq "A POSIX way to do printf %q" bw -printfq() { printf "'%s'\\n" "$(printf '%s' "$1" | sed -e "s/'/'\\\\''/g")"; } +printfq() { printf "'%s'\\n" "$(printf '%s' "\$1" | sed -e "s/'/'\\\\''/g")"; } $0 endsnippet