diff options
Diffstat (limited to '')
-rw-r--r-- | yamllint/cli.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/yamllint/cli.py b/yamllint/cli.py index 604e594..9a39bd8 100644 --- a/yamllint/cli.py +++ b/yamllint/cli.py @@ -19,8 +19,7 @@ import os import platform import sys -from yamllint import APP_DESCRIPTION, APP_NAME, APP_VERSION -from yamllint import linter +from yamllint import APP_DESCRIPTION, APP_NAME, APP_VERSION, linter from yamllint.config import YamlLintConfig, YamlLintConfigError from yamllint.linter import PROBLEM_LEVELS @@ -28,10 +27,11 @@ from yamllint.linter import PROBLEM_LEVELS def find_files_recursively(items, conf): for item in items: if os.path.isdir(item): - for root, dirnames, filenames in os.walk(item): + for root, _dirnames, filenames in os.walk(item): for f in filenames: filepath = os.path.join(root, f) - if conf.is_yaml_file(filepath): + if (conf.is_yaml_file(filepath) and + not conf.is_file_ignored(filepath)): yield filepath else: yield item @@ -79,9 +79,9 @@ class Format: @staticmethod def github(problem, filename): - line = f'::{problem.level} file={format(filename)},' \ - f'line={format(problem.line)},col={format(problem.column)}' \ - f'::{format(problem.line)}:{format(problem.column)} ' + line = f'::{problem.level} file={filename},' \ + f'line={problem.line},col={problem.column}' \ + f'::{problem.line}:{problem.column} ' if problem.rule: line += f'[{problem.rule}] ' line += problem.desc |