mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-13 08:01:09 +00:00
Fix indentation and formatting of previous commit.
This commit is contained in:
parent
1747986a88
commit
6aafc793dd
@ -177,13 +177,13 @@ class pbuilder_dist:
|
||||
+ self.build_architecture)
|
||||
|
||||
prefix = os.path.join(self.base, self.chroot_string)
|
||||
if '--buildresult' not in remaining_arguments:
|
||||
if '--buildresult' not in remaining_arguments:
|
||||
result = '%s_result/' % prefix
|
||||
else:
|
||||
location_of_arg = remaining_arguments.index('--buildresult')
|
||||
result = remaining_arguments[location_of_arg+1]
|
||||
remaining_arguments.pop(location_of_arg+1)
|
||||
remaining_arguments.pop(location_of_arg)
|
||||
else:
|
||||
location_of_arg = remaining_arguments.index('--buildresult')
|
||||
result = remaining_arguments[location_of_arg+1]
|
||||
remaining_arguments.pop(location_of_arg+1)
|
||||
remaining_arguments.pop(location_of_arg)
|
||||
|
||||
if not self.logfile and self.operation != 'login':
|
||||
self.logfile = os.path.normpath('%s/last_operation.log' % result)
|
||||
|
@ -50,15 +50,17 @@ class Pbuilder(Builder):
|
||||
Logger.command(cmd)
|
||||
return subprocess.call(cmd)
|
||||
|
||||
|
||||
class Pbuilderdist(Builder):
|
||||
def __init__(self):
|
||||
Builder.__init__(self, "pbuilder-dist")
|
||||
Builder.__init__(self, "pbuilder-dist")
|
||||
|
||||
def build(self, dsc_file, dist, result_directory):
|
||||
cmd = ["pbuilder-dist", dist, self.architecture,
|
||||
"build", dsc_file, "--buildresult", result_directory]
|
||||
Logger.command(cmd)
|
||||
return subprocess.call(cmd)
|
||||
cmd = ["pbuilder-dist", dist, self.architecture,
|
||||
"build", dsc_file, "--buildresult", result_directory]
|
||||
Logger.command(cmd)
|
||||
return subprocess.call(cmd)
|
||||
|
||||
|
||||
class Sbuild(Builder):
|
||||
def __init__(self):
|
||||
@ -84,9 +86,9 @@ def getBuilder(builder=None):
|
||||
if builder == 'pbuilder':
|
||||
return Pbuilder()
|
||||
elif builder == 'pbuilder-dist':
|
||||
return Pbuilderdist()
|
||||
return Pbuilderdist()
|
||||
elif builder == 'sbuild':
|
||||
return Sbuild()
|
||||
|
||||
Logger.error("Unsupported builder specified: %s. Only pbuilder, pbuilder-dist and "
|
||||
"sbuild are supported." % builder)
|
||||
Logger.error("Unsupported builder specified: %s. Only pbuilder, "
|
||||
"pbuilder-dist and sbuild are supported." % builder)
|
||||
|
Loading…
x
Reference in New Issue
Block a user