branch: --no-optional-locks arg needs to be given to git

The special argument --no-optional-lock applies to the main git command,
and not to the git subcommand `git status`. So move it there, to prevent
an error with git.

closes #2651

Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Christian Brabandt 2023-10-04 21:00:17 +02:00
parent e6bb8427dc
commit f1ba5a03db
No known key found for this signature in database
GPG Key ID: F3F92DA383FDDE09

View File

@ -17,8 +17,8 @@ scriptencoding utf-8
let s:vcs_config = {
\ 'git': {
\ 'exe': 'git',
\ 'cmd': 'git status --porcelain --no-optional-locks -- ',
\ 'dirty': 'git status -uno --porcelain --no-optional-locks --ignore-submodules',
\ 'cmd': 'git --no-optional-locks status --porcelain -- ',
\ 'dirty': 'git --no-optional-locks status -uno --porcelain --ignore-submodules',
\ 'untracked_mark': '??',
\ 'exclude': '\.git',
\ 'update_branch': 's:update_git_branch',