Commit ceedf60c authored by Tim-Philipp Müller's avatar Tim-Philipp Müller
Browse files

meson: fix get-version script for git worktrees

For git worktree directories .git is not a directory
but a file that points to the real .git dir.
parent 16395923
Pipeline #2519 passed with stages
in 4 minutes and 55 seconds
......@@ -31,7 +31,7 @@ if __name__ == '__main__':
# check if git checkout
git_dir = os.path.join(srcroot, '.git')
is_git = os.path.isdir(git_dir)
is_git = os.path.isdir(git_dir) or os.path.isfile(git_dir)
have_git = shutil.which('git') is not None
if is_git and have_git:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment