More coding style cleanup
Fixing more issues found with pylint. Some that were supposed to
have been fixed in the previous sweep (Ie0db839e) but were missed:
C0321: More than one statement on a single line
W0622: Redefining built-in 'name'
And some more:
W0631: Using possibly undefined loop variable 'name'
W0223: Method 'name' is abstract in class 'name' but is not overridden
W0231: __init__ method from base class 'name' is not called
Change-Id: Ie119183708609d6279e973057a385fde864230c3
diff --git a/subcmds/__init__.py b/subcmds/__init__.py
index a2286e7..1fac802 100644
--- a/subcmds/__init__.py
+++ b/subcmds/__init__.py
@@ -15,7 +15,7 @@
import os
-all = {}
+all_commands = {}
my_dir = os.path.dirname(__file__)
for py in os.listdir(my_dir):
@@ -43,7 +43,7 @@
name = name.replace('_', '-')
cmd.NAME = name
- all[name] = cmd
+ all_commands[name] = cmd
-if 'help' in all:
- all['help'].commands = all
+if 'help' in all_commands:
+ all_commands['help'].commands = all_commands