From 4a23c47a924116b4ac8b8afb68ce1f372fa5c448 Mon Sep 17 00:00:00 2001 From: Přemysl Eric Janouch
Date: Wed, 17 Apr 2024 01:44:57 +0200 Subject: Adjust shell quoting --- acid.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'acid.go') diff --git a/acid.go b/acid.go index 2c59c38..17ca23b 100644 --- a/acid.go +++ b/acid.go @@ -102,7 +102,7 @@ var shellFuncs = ttemplate.FuncMap{ "quote": func(word string) string { // History expansion is annoying, don't let it cut us. if strings.IndexRune(word, '!') >= 0 { - return "'" + strings.ReplaceAll(word, "'", `'"'"'`) + "'" + return "'" + strings.ReplaceAll(word, "'", `'\''`) + "'" } const special = "$`\"\\" -- cgit v1.2.3-70-g09d2