diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4b44785cdfa7d88e856410f8edf9eb86461e6432..32fc2d20783f1ab735431355333e83c735ea7596 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -17,6 +17,8 @@ docs: pylint: stage: test image: it4innovations/docker-pycheck:latest + before_script: + - source /opt/.venv3/bin/activate script: - pylint $(find . -name "*.py" -not -name "feslicescript.py") diff --git a/mkdocs.yml b/mkdocs.yml index 524d5662e2a0d3a07de239214184165b37a94678..bc2c45639d28878fad3ef4f60a9bf7582f617cea 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -240,6 +240,7 @@ markdown_extensions: - pymdownx.snippets: base_path: snippets - pymdownx.tabbed: + - pymdownx.superfences google_analytics: - 'UA-90498826-1' diff --git a/scripts/combinations.py b/scripts/combinations.py index 67cf39b0df3854f20807cd44493049a35666ca21..5982443b93c0811775c007970baae673906f35b3 100644 --- a/scripts/combinations.py +++ b/scripts/combinations.py @@ -2,6 +2,8 @@ # -*- coding: utf-8 -*- """ combinations """ +from __future__ import print_function + import itertools import re @@ -9,5 +11,5 @@ CHARS = ['A', 'S', 'U', 'T', 'D'] MASK = ''.join(reversed(CHARS)) for i in range(1, len(CHARS)+1): for comb in itertools.combinations(CHARS, i): - reg = "[^%s]" % ''.join(comb) - print re.sub(reg, "-", MASK) + REG = "[^%s]" % ''.join(comb) + print(re.sub(REG, "-", MASK)) diff --git a/scripts/matrix.py b/scripts/matrix.py index a285cabbd5a0507bc5bafbfc3084eb6e5ca757a7..4f2c25060a8dab6589900161983b6bce12af54ec 100644 --- a/scripts/matrix.py +++ b/scripts/matrix.py @@ -2,16 +2,18 @@ # -*- coding: utf-8 -*- """ matrix """ +from __future__ import print_function + import itertools CHARS = ['A', 'S', 'U', 'P', 'D', 'B'] MASK = ''.join(reversed(CHARS)) for bits in itertools.product([0, 1], repeat=len(CHARS)): - s = "".join(str(bit) for bit in bits) - ns = "" - for i, _ in enumerate(s): - if s[i] == "1": - ns += MASK[i] + SBIT = "".join(str(bit) for bit in bits) + NST = "" + for i, _ in enumerate(SBIT): + if SBIT[i] == "1": + NST += MASK[i] else: - ns += "-" - print ns + NST += "-" + print(NST) diff --git a/scripts/modules_matrix.py b/scripts/modules_matrix.py index a2e3acb5e0d4ca10b08a23fe08ad7b451df785eb..9a8f4a54bbe0f5c1ba81ec98df40af1b7d9d6e77 100755 --- a/scripts/modules_matrix.py +++ b/scripts/modules_matrix.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python2 +#!/usr/bin/env python # -*- coding: utf-8 -*- """ modules_matrix """ @@ -133,7 +133,6 @@ def main(): if arg.json: print(json.dumps(packages_json(software))) else: - print(datalist) print_hint() print_software(software) diff --git a/scripts/titlemd.py b/scripts/titlemd.py index 39fb6b0a03e0cbbe61bde62b55f9dbf30909d0ad..73520c6b466d64c4c2a45004545d036af092dcb2 100755 --- a/scripts/titlemd.py +++ b/scripts/titlemd.py @@ -39,15 +39,13 @@ def linestart(line, disabled, test, prev_line=None): if test: if (line.startswith("``") or line.startswith("extra:")) and not disabled: return True - else: - if (line.startswith("``") or prev_line.startswith("pages:")) and disabled: - return False + if (line.startswith("``") or prev_line.startswith("pages:")) and disabled: + return False else: if line.startswith("``") and not disabled: return True - else: - if line.startswith("``") and disabled: - return False + if line.startswith("``") and disabled: + return False return disabled def testdata(arg):