From 8a68ff96057ec58e524a3e41a2d8dca7b5d016bc Mon Sep 17 00:00:00 2001 From: David Pursehouse Date: Mon, 24 Sep 2012 12:15:13 +0900 Subject: Coding style cleanup Fix the following issues reported by pylint: C0321: More than one statement on a single line W0622: Redefining built-in 'name' W0612: Unused variable 'name' W0613: Unused argument 'name' W0102: Dangerous default value 'value' as argument W0105: String statement has no effect Also fixed a few cases of inconsistent indentation. Change-Id: Ie0db839e7c57d576cff12d8c055fe87030d00744 --- subcmds/prune.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'subcmds/prune.py') diff --git a/subcmds/prune.py b/subcmds/prune.py index f412bd48..c50a5507 100644 --- a/subcmds/prune.py +++ b/subcmds/prune.py @@ -24,11 +24,11 @@ class Prune(PagedCommand): """ def Execute(self, opt, args): - all = [] + all_branches = [] for project in self.GetProjects(args): - all.extend(project.PruneHeads()) + all_branches.extend(project.PruneHeads()) - if not all: + if not all_branches: return class Report(Coloring): @@ -36,13 +36,13 @@ class Prune(PagedCommand): Coloring.__init__(self, config, 'status') self.project = self.printer('header', attr='bold') - out = Report(all[0].project.config) + out = Report(all_branches[0].project.config) out.project('Pending Branches') out.nl() project = None - for branch in all: + for branch in all_branches: if project != branch.project: project = branch.project out.nl() -- cgit v1.2.3-54-g00ecf