aboutsummaryrefslogtreecommitdiff
path: root/autoload/shebang_create_exec.vim
diff options
context:
space:
mode:
Diffstat (limited to 'autoload/shebang_create_exec.vim')
-rw-r--r--autoload/shebang_create_exec.vim2
1 files changed, 1 insertions, 1 deletions
diff --git a/autoload/shebang_create_exec.vim b/autoload/shebang_create_exec.vim
index 8ae659e..60d2276 100644
--- a/autoload/shebang_create_exec.vim
+++ b/autoload/shebang_create_exec.vim
@@ -73,7 +73,7 @@ function! s:MakeExecutable(filename) abort
" shellescape() if we've got it, or manual UNIX sh quoting if not
let filename_escaped = exists('*shellescape')
\ ? shellescape(filename)
- \ : '''' . escape(filename, '''') . ''''
+ \ : "'" . substitute(filename, "'", "'\\''", 'g') . "'"
" Try to make the file executable with a fork to chmod(1)
call system('chmod +x '.filename_escaped)