mirror of
https://github.com/airblade/vim-gitgutter.git
synced 2025-11-10 12:33:47 -05:00
Use /bin/sh as default shell.
- /bin/bash is not part of OpenBSD. - We need only a POSIX shell, not bash specifically. Closes #340.
This commit is contained in:
committed by
Andy Stewart
parent
90c558b1dc
commit
377c71d982
@@ -18,7 +18,7 @@ function! gitgutter#async#execute(cmd) abort
|
|||||||
|
|
||||||
if has('nvim')
|
if has('nvim')
|
||||||
if has('unix')
|
if has('unix')
|
||||||
let command = ["/bin/bash", "-c", a:cmd]
|
let command = ["/bin/sh", "-c", a:cmd]
|
||||||
elseif has('win32')
|
elseif has('win32')
|
||||||
let command = ["cmd.exe", "/c", a:cmd]
|
let command = ["cmd.exe", "/c", a:cmd]
|
||||||
else
|
else
|
||||||
@@ -49,7 +49,7 @@ function! gitgutter#async#execute(cmd) abort
|
|||||||
" only occurs when a file is not tracked by git).
|
" only occurs when a file is not tracked by git).
|
||||||
|
|
||||||
if has('unix')
|
if has('unix')
|
||||||
let command = ["/bin/bash", "-c", a:cmd]
|
let command = ["/bin/sh", "-c", a:cmd]
|
||||||
elseif has('win32')
|
elseif has('win32')
|
||||||
" Help docs recommend {command} be a string on Windows. But I think
|
" Help docs recommend {command} be a string on Windows. But I think
|
||||||
" they also say that will run the command directly, which I believe would
|
" they also say that will run the command directly, which I believe would
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ function! gitgutter#utility#use_known_shell() abort
|
|||||||
if has('unix')
|
if has('unix')
|
||||||
let s:shell = &shell
|
let s:shell = &shell
|
||||||
let s:shellcmdflag = &shellcmdflag
|
let s:shellcmdflag = &shellcmdflag
|
||||||
set shell=/bin/bash
|
set shell=/bin/sh
|
||||||
set shellcmdflag=-c
|
set shellcmdflag=-c
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|||||||
Reference in New Issue
Block a user