Commit 9aeaa593 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 2985a40a
Pipeline #2479 passed with stages
in 8 minutes and 19 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:
Supports Markdown
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