Put --homedir at the start of the command line
Closes jamessan/vim-gnupg#20 Signed-off-by: James McCoy <vega.james@gmail.com>
This commit is contained in:
parent
a1bc9f1ca0
commit
40cec4652c
@ -1,5 +1,5 @@
|
||||
" Name: gnupg.vim
|
||||
" Last Change: 2014 Jul 27
|
||||
" Last Change: 2014 Aug 10
|
||||
" Maintainer: James McCoy <vega.james@gmail.com>
|
||||
" Original Author: Markus Braun <markus.braun@krawel.de>
|
||||
" Summary: Vim plugin for transparent editing of gpg encrypted files.
|
||||
@ -1267,10 +1267,11 @@ endfunction
|
||||
" Returns: command output
|
||||
"
|
||||
function s:GPGSystem(dict)
|
||||
let commandline = printf('%s %s', s:GPGCommand, a:dict.args)
|
||||
let commandline = s:GPGCommand
|
||||
if (!empty(g:GPGHomedir))
|
||||
let commandline .= ' --homedir ' . shellescape(g:GPGHomedir)
|
||||
endif
|
||||
let commandline .= ' ' . a:dict.args
|
||||
let commandline .= ' ' . s:stderrredirnull
|
||||
call s:GPGDebug(a:dict.level, "command: ". commandline)
|
||||
|
||||
@ -1293,10 +1294,11 @@ endfunction
|
||||
" redirect - Shell redirect to use, if needed
|
||||
"
|
||||
function s:GPGExecute(dict)
|
||||
let commandline = printf('%s%s %s', a:dict.ex, s:GPGCommand, a:dict.args)
|
||||
let commandline = printf('%s%s', a:dict.ex, s:GPGCommand)
|
||||
if (!empty(g:GPGHomedir))
|
||||
let commandline .= ' --homedir ' . shellescape(g:GPGHomedir, 1)
|
||||
endif
|
||||
let commandline .= ' ' . a:dict.args
|
||||
if (has_key(a:dict, 'redirect'))
|
||||
let commandline .= ' ' . a:dict.redirect
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user