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

Unified Diff: builder.py

Issue 6594128: Use cros_workon from path rather than from scripts dir. (Closed) Base URL: http://git.chromium.org/git/dev-util.git@master
Patch Set: Created 9 years, 10 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: builder.py
diff --git a/builder.py b/builder.py
index e7bccae718b3c8f24f35dc4b9d93953e590ffa22..bf83c3e7f82462f240e23e8b5ee52262e1c39afd 100644
--- a/builder.py
+++ b/builder.py
@@ -15,9 +15,6 @@ import cherrypy
def _OutputOf(command):
"""Runs command, a list of arguments beginning with an executable.
- If the executable begins with "scripts/", the path is adjusted to
- the scripts directory of this chroot.
-
Args:
command: A list of arguments, beginning with the executable
Returns:
@@ -25,10 +22,6 @@ def _OutputOf(command):
Raises:
subprocess.CalledProcessError if the command fails
"""
- scripts = 'scripts/'
- if command[0].find(scripts) == 0:
- server_dir = os.path.dirname(os.path.abspath(sys.argv[0]))
- command[0] = command[0].replace(scripts, server_dir + '/../../' + scripts)
command_name = ' '.join(command)
cherrypy.log('Executing: ' + command_name, 'BUILD')
@@ -44,12 +37,12 @@ class Builder(object):
def _ShouldBeWorkedOn(self, board, pkg):
"""Is pkg a package that could be worked on, but is not?"""
- if pkg in _OutputOf(['scripts/cros_workon', '--board=' + board, 'list']):
+ if pkg in _OutputOf(['cros_workon', '--board=' + board, 'list']):
return False
# If it's in the list of possible workon targets, we should be working on it
return pkg in _OutputOf([
- 'scripts/cros_workon', '--board=' + board, 'list', '--all'])
+ 'cros_workon', '--board=' + board, 'list', '--all'])
def SetError(self, text):
cherrypy.response.status = 500
« 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