Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1821)

Unified Diff: native_client_sdk/src/build_tools/build_version.py

Issue 559233002: [NaCl SDK] Never check SVN or git-svn for Chromium repo. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 cb9448834e5f7267d1ea2d0b88dfb25fb8a1190b..014b86e9927814fdb282cbbcdb9441ad29f51cf2 100644
--- a/native_client_sdk/src/build_tools/build_version.py
+++ b/native_client_sdk/src/build_tools/build_version.py
@@ -28,7 +28,7 @@ def ChromeVersion():
Returns:
Chrome version string or trunk + svn rev.
'''
- info = FetchVersionInfo()
+ info = FetchGitCommitPosition()
if info.url == 'git':
_, ref, revision = ParseCommitPosition(info.revision)
if ref == 'refs/heads/master':
@@ -88,26 +88,7 @@ def NaClRevision():
The NaCl revision as a string. e.g. "12345"
'''
nacl_dir = os.path.join(SRC_DIR, 'native_client')
- return FetchVersionInfo(nacl_dir, 'native_client').revision
-
-
-def FetchVersionInfo(directory=None,
- directory_regex_prior_to_src_url='chrome|blink|svn'):
- '''Returns the last change (in the form of a branch, revision tuple),
- from some appropriate revision control system.
-
- TODO(binji): This is copied from lastchange.py. Remove this function and use
- lastchange.py directly when the dust settles. (see crbug.com/406783)
- '''
- svn_url_regex = re.compile(
- r'.*/(' + directory_regex_prior_to_src_url + r')(/.*)')
-
- version_info = (lastchange.FetchSVNRevision(directory, svn_url_regex) or
- lastchange.FetchGitSVNRevision(directory, svn_url_regex) or
- FetchGitCommitPosition(directory))
- if not version_info:
- version_info = lastchange.VersionInfo(None, None)
- return version_info
+ return lastchange.FetchVersionInfo(None, nacl_dir, 'native_client').revision
def FetchGitCommitPosition(directory=None):
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698