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
diff --git a/subcmds/help.py b/subcmds/help.py
index 0df3c14..375d04d 100644
--- a/subcmds/help.py
+++ b/subcmds/help.py
@@ -120,8 +120,8 @@
m = asciidoc_hdr.match(para)
if m:
title = m.group(1)
- type = m.group(2)
- if type[0] in ('=', '-'):
+ section_type = m.group(2)
+ if section_type[0] in ('=', '-'):
p = self.heading
else:
def _p(fmt, *args):
@@ -131,7 +131,7 @@
p('%s', title)
self.nl()
- p('%s', ''.ljust(len(title),type[0]))
+ p('%s', ''.ljust(len(title),section_type[0]))
self.nl()
continue