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

Unified Diff: gclient_scm.py

Issue 208060: gclient: store revision as a string and not int (Closed)
Patch Set: Created 11 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 | « gclient.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gclient_scm.py
diff --git a/gclient_scm.py b/gclient_scm.py
index 51a3f5f8db4d081638f4cd0423b841bffae6b53c..61a58fdd53ef8988978c93dc7a2f7ff526c0d5f1 100644
--- a/gclient_scm.py
+++ b/gclient_scm.py
@@ -133,15 +133,15 @@ class SVNWrapper(SCMWrapper):
if options.revision:
# Override the revision number.
url = '%s@%s' % (components[0], str(options.revision))
- revision = int(options.revision)
+ revision = options.revision
forced_revision = True
elif len(components) == 2:
- revision = int(components[1])
+ revision = components[1]
forced_revision = True
rev_str = ""
if revision:
- rev_str = ' at %d' % revision
+ rev_str = ' at %s' % revision
if not os.path.exists(checkout_path):
# We need to checkout.
@@ -163,8 +163,8 @@ class SVNWrapper(SCMWrapper):
# Retrieve the current HEAD version because svn is slow at null updates.
if not revision:
from_info_live = CaptureSVNInfo(from_info['URL'], '.')
- revision = int(from_info_live['Revision'])
- rev_str = ' at %d' % revision
+ revision = from_info_live['Revision']
+ rev_str = ' at %s' % revision
if from_info['URL'] != components[0]:
to_info = CaptureSVNInfo(url, '.')
@@ -513,7 +513,7 @@ def CaptureSVNHeadRevision(url):
"""
info = CaptureSVN(["info", "--xml", url], os.getcwd())
dom = xml.dom.minidom.parseString(info)
- return int(dom.getElementsByTagName('entry')[0].getAttribute('revision'))
+ return dom.getElementsByTagName('entry')[0].getAttribute('revision')
def CaptureSVNStatus(files):
« no previous file with comments | « gclient.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698