From a1224ef14b4c86065bb283dc2d63885802cd49b4 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Fri, 8 Jun 2018 10:23:18 -0700 Subject: [PATCH] tools,gyp: fix regex for version matching Tool versions can be 10 and higher. Float patch from node-gyp to accommodate this fact of life. PR-URL: https://github.com/nodejs/node/pull/21216 Refs: https://github.com/nodejs/node-gyp/commit/293092c362febffe19f72712467565045e08e8f1 Reviewed-By: Refael Ackermann Reviewed-By: Ben Noordhuis Reviewed-By: Richard Lau Reviewed-By: Anna Henningsen --- tools/gyp/pylib/gyp/xcode_emulation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/gyp/pylib/gyp/xcode_emulation.py b/tools/gyp/pylib/gyp/xcode_emulation.py index 407ead074bbe7e..5ae81ea2935570 100644 --- a/tools/gyp/pylib/gyp/xcode_emulation.py +++ b/tools/gyp/pylib/gyp/xcode_emulation.py @@ -1262,7 +1262,7 @@ def XcodeVersion(): except: version = CLTVersion() if version: - version = re.match(r'(\d\.\d\.?\d*)', version).groups()[0] + version = re.match(r'(\d+\.\d+\.?\d*)', version).groups()[0] else: raise GypError("No Xcode or CLT version detected!") # The CLT has no build information, so we return an empty string.