diff options
author | Matt Martz <matt@sivel.net> | 2017-02-07 09:49:55 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-07 09:49:55 -0600 |
commit | 5942de603d1bbc942ef98d70ccc6ec00944cd46b (patch) | |
tree | 9267d6e2bbd9037f469ff1172c763a3d372857ad /hacking | |
parent | 0de96d68f6830bd4f9832e2318779ee39328a976 (diff) | |
download | ansible-5942de603d1bbc942ef98d70ccc6ec00944cd46b.tar.gz |
Legacy pep8 clean fixes for contrib and hacking (#21081)
Diffstat (limited to 'hacking')
-rwxr-xr-x | hacking/metadata-tool.py | 8 | ||||
-rwxr-xr-x | hacking/module_formatter.py | 10 |
2 files changed, 14 insertions, 4 deletions
diff --git a/hacking/metadata-tool.py b/hacking/metadata-tool.py index df0a2fb702..795511f7f9 100755 --- a/hacking/metadata-tool.py +++ b/hacking/metadata-tool.py @@ -560,8 +560,12 @@ def report(version=None): print('== Summary ==') print('No Metadata: {0} Has Metadata: {1}'.format(len(no_metadata), len(has_metadata))) - print('Supported by core: {0} Supported by community: {1} Supported by committer: {2}'.format(len(support['core']), len(support['community']), len(support['committer']))) - print('Status StableInterface: {0} Status Preview: {1} Status Deprecated: {2} Status Removed: {3}'.format(len(status['stableinterface']), len(status['preview']), len(status['deprecated']), len(status['removed']))) + print('Supported by core: {0} Supported by community: {1} Supported by committer: {2}'.format(len(support['core']), len(support['community']), + len(support['committer']))) + print('Status StableInterface: {0} Status Preview: {1} Status Deprecated: {2} Status Removed: {3}'.format(len(status['stableinterface']), + len(status['preview']), + len(status['deprecated']), + len(status['removed']))) return 0 diff --git a/hacking/module_formatter.py b/hacking/module_formatter.py index 33204ff1b7..4f132aa0cf 100755 --- a/hacking/module_formatter.py +++ b/hacking/module_formatter.py @@ -135,7 +135,12 @@ def list_modules(module_dir, depth=0): # * windows powershell modules have documentation stubs in python docstring # format (they are not executed) so skip the ps1 format files # * One glob level for every module level that we're going to traverse - files = glob.glob("%s/*.py" % module_dir) + glob.glob("%s/*/*.py" % module_dir) + glob.glob("%s/*/*/*.py" % module_dir) + glob.glob("%s/*/*/*/*.py" % module_dir) + files = ( + glob.glob("%s/*.py" % module_dir) + + glob.glob("%s/*/*.py" % module_dir) + + glob.glob("%s/*/*/*.py" % module_dir) + + glob.glob("%s/*/*/*/*.py" % module_dir) + ) for module_path in files: if module_path.endswith('__init__.py'): @@ -412,7 +417,8 @@ def process_category(category, categories, options, env, template, outputname): category_file.write("""\n\n .. note:: - - %s: This marks a module as deprecated, which means a module is kept for backwards compatibility but usage is discouraged. The module documentation details page may explain more about this rationale. + - %s: This marks a module as deprecated, which means a module is kept for backwards compatibility but usage is discouraged. + The module documentation details page may explain more about this rationale. """ % DEPRECATED) category_file.close() |