patch-git: Support git worktree
After “git worktree”, .git is a text file, not a directory. Resolves: RHEL-121947
This commit is contained in:
parent
b16cb36857
commit
50e34d07ff
@ -487,7 +487,7 @@ local function generate_files()
|
||||
-- True if %_sourcedir refers to a Git repository and git is installed.
|
||||
local have_git = (posix == nil -- Not running under rpm.
|
||||
or (posix.access('/usr/bin/git', 'x')
|
||||
and posix.access(sourcedir .. '/.git/.', 'x')))
|
||||
and posix.access(sourcedir .. '/.git', 'r')))
|
||||
local commit_marker_contents -- For git_commit_file.
|
||||
if have_git then
|
||||
commit_marker_contents =
|
||||
|
||||
Loading…
Reference in New Issue
Block a user