| Index: native_client_sdk/src/build_tools/build_version.py
|
| diff --git a/native_client_sdk/src/build_tools/build_version.py b/native_client_sdk/src/build_tools/build_version.py
|
| index 375c24a5fe8d0a04b7282d234dfdf1aa10c73e0b..ced1a2540d5cb0e85c113207a622edd069ef796c 100644
|
| --- a/native_client_sdk/src/build_tools/build_version.py
|
| +++ b/native_client_sdk/src/build_tools/build_version.py
|
| @@ -29,7 +29,7 @@ def ChromeVersion():
|
| Chrome version string or trunk + svn rev.
|
| '''
|
| info = FetchVersionInfo()
|
| - if info.url.startswith('/trunk/'):
|
| + if info.url == 'refs/heads/master':
|
| return 'trunk.%s' % info.revision
|
| else:
|
| return ChromeVersionNoTrunk()
|
| @@ -110,14 +110,11 @@ def FetchGitCommitPosition(directory=None):
|
| """
|
| proc = lastchange.RunGitCommand(directory,
|
| ['show', '-s', '--format=%B', 'HEAD'])
|
| - pos = ''
|
| if proc:
|
| output = proc.communicate()[0]
|
| if proc.returncode == 0 and output:
|
| for line in reversed(output.splitlines()):
|
| - match = re.search('Cr-Commit-Position: .*@{#(\d+)}', line)
|
| + match = re.search('Cr-Commit-Position: (.*)@{#(\d+)}', line)
|
| if match:
|
| - pos = match.group(1)
|
| - if not pos:
|
| - return lastchange.VersionInfo(None, None)
|
| - return lastchange.VersionInfo('git', pos)
|
| + return lastchange.VersionInfo(match.group(1), match.group(2))
|
| + return lastchange.VersionInfo(None, None)
|
|
|