Skip to content
Snippets Groups Projects
Commit 10af87bc authored by gyulaid's avatar gyulaid
Browse files

output hotfix

parent 05857155
No related branches found
No related tags found
No related merge requests found
...@@ -54,7 +54,6 @@ class ConfigParser: ...@@ -54,7 +54,6 @@ class ConfigParser:
paths = [] paths = []
for path in changes["paths"]: for path in changes["paths"]:
paths.append(os.path.abspath(path)) paths.append(os.path.abspath(path))
print(paths)
# TODO: Error handling # TODO: Error handling
command = ["git", "diff", "--name-only", target] command = ["git", "diff", "--name-only", target]
with subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE) as p: with subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE) as p:
...@@ -64,8 +63,9 @@ class ConfigParser: ...@@ -64,8 +63,9 @@ class ConfigParser:
for path in paths: for path in paths:
spec_path = os.path.abspath(path) spec_path = os.path.abspath(path)
if change_path.startswith(spec_path): if change_path.startswith(spec_path):
print(f"Modified file: {change_path}") if self.verbose:
print(f"Path match: {path}") print(f"[Alice] Modified file: {change_path}")
print(f"[Alice] Path match: {path}")
return True return True
except KeyError: except KeyError:
raise ConfigException(f"Invalid 'changes' config: {changes}") raise ConfigException(f"Invalid 'changes' config: {changes}")
...@@ -82,5 +82,5 @@ class ConfigParser: ...@@ -82,5 +82,5 @@ class ConfigParser:
runner.run(job_spec) runner.run(job_spec)
return "SUCCESS" return "SUCCESS"
else: else:
print("SKIP, no change detected") return "SKIP, no change detected"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment