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

Side by Side Diff: tools/utils.py

Issue 1086613002: Add annotated steps for dart_services (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/bots/dart_services.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 # for details. All rights reserved. Use of this source code is governed by a 2 # for details. All rights reserved. Use of this source code is governed by a
3 # BSD-style license that can be found in the LICENSE file. 3 # BSD-style license that can be found in the LICENSE file.
4 4
5 # This file contains a set of utilities functions used by other Python-based 5 # This file contains a set of utilities functions used by other Python-based
6 # scripts. 6 # scripts.
7 7
8 import commands 8 import commands
9 import os 9 import os
10 import platform 10 import platform
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 265
266 def GetBuildDir(host_os): 266 def GetBuildDir(host_os):
267 return BUILD_ROOT[host_os] 267 return BUILD_ROOT[host_os]
268 268
269 def GetBuildRoot(host_os, mode=None, arch=None, target_os=None): 269 def GetBuildRoot(host_os, mode=None, arch=None, target_os=None):
270 build_root = GetBuildDir(host_os) 270 build_root = GetBuildDir(host_os)
271 if mode: 271 if mode:
272 build_root = os.path.join(build_root, GetBuildConf(mode, arch, target_os)) 272 build_root = os.path.join(build_root, GetBuildConf(mode, arch, target_os))
273 return build_root 273 return build_root
274 274
275 def GetBuildSdkBin(host_os, mode=None, arch=None, target_os=None):
276 build_root = GetBuildRoot(host_os, mode, arch, target_os)
277 return os.path.join(build_root, 'dart-sdk', 'bin')
278
275 def GetBaseDir(): 279 def GetBaseDir():
276 return BASE_DIR 280 return BASE_DIR
277 281
278 def GetShortVersion(): 282 def GetShortVersion():
279 version = ReadVersionFile() 283 version = ReadVersionFile()
280 return ('%s.%s.%s.%s.%s' % ( 284 return ('%s.%s.%s.%s.%s' % (
281 version.major, version.minor, version.patch, version.prerelease, 285 version.major, version.minor, version.patch, version.prerelease,
282 version.prerelease_patch)) 286 version.prerelease_patch))
283 287
284 def GetSemanticSDKVersion(ignore_svn_revision=False): 288 def GetSemanticSDKVersion(ignore_svn_revision=False):
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 os.chdir(self._working_directory) 601 os.chdir(self._working_directory)
598 602
599 def __exit__(self, *_): 603 def __exit__(self, *_):
600 print "Enter directory = ", self._old_cwd 604 print "Enter directory = ", self._old_cwd
601 os.chdir(self._old_cwd) 605 os.chdir(self._old_cwd)
602 606
603 607
604 if __name__ == "__main__": 608 if __name__ == "__main__":
605 import sys 609 import sys
606 Main() 610 Main()
OLDNEW
« no previous file with comments | « tools/bots/dart_services.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698