gn build: Use "git rev-parse --git-dir" to discover the path to the .git directory.
authorPeter Collingbourne <peter@pcc.me.uk>
Thu, 10 Jan 2019 21:57:07 +0000 (21:57 +0000)
committerPeter Collingbourne <peter@pcc.me.uk>
Thu, 10 Jan 2019 21:57:07 +0000 (21:57 +0000)
commitffcd37c5fd86eb79a1e29da23572504014faf29c
treeade072c6a895cfc862861a2a3bfbd8bf5e130cbf
parentcb7d968f73f827ef81d224a9332b49787c351044
gn build: Use "git rev-parse --git-dir" to discover the path to the .git directory.

This makes it compatible with worktrees.

Differential Revision: https://reviews.llvm.org/D56422

llvm-svn: 350897
llvm/utils/gn/build/write_vcsrevision.py