mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #38457 from bshelton229/git-latest-head-bug
Stops git.latest checking for local changes in a bare repo
This commit is contained in:
commit
ed2ba4bd1b
1 changed files with 4 additions and 0 deletions
|
@ -879,7 +879,11 @@ def latest(name,
|
|||
|
||||
revs_match = _revs_equal(local_rev, remote_rev, remote_rev_type)
|
||||
try:
|
||||
# If not a bare repo, check `git diff HEAD` to determine if
|
||||
# there are local changes.
|
||||
local_changes = bool(
|
||||
not bare
|
||||
and
|
||||
__salt__['git.diff'](target,
|
||||
'HEAD',
|
||||
user=user,
|
||||
|
|
Loading…
Add table
Reference in a new issue