From 5b1c955cc426309861f46a28f0b5a0526e4893d2 Mon Sep 17 00:00:00 2001 From: Isaac Milarsky Date: Tue, 24 Sep 2024 12:52:57 -0500 Subject: [PATCH] path issue Signed-off-by: Isaac Milarsky --- .../.github/repometrics/hooks/pre_gen_project.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tier1/{{cookiecutter.project_slug}}/.github/repometrics/hooks/pre_gen_project.py b/tier1/{{cookiecutter.project_slug}}/.github/repometrics/hooks/pre_gen_project.py index 107dea3..0aedd29 100644 --- a/tier1/{{cookiecutter.project_slug}}/.github/repometrics/hooks/pre_gen_project.py +++ b/tier1/{{cookiecutter.project_slug}}/.github/repometrics/hooks/pre_gen_project.py @@ -7,7 +7,8 @@ if shutil.which('scc') is not None: try: #Run scc and load results into a dictionary - d = json.loads(subprocess.run(["scc", "--format","json2"],check=True, capture_output=True).stdout) + #assuming we are in the .git directory of the repo + d = json.loads(subprocess.run(["scc","..", "--format","json2"],check=True, capture_output=True).stdout) #inject a default value for labor hours calculated from scc cookiecutter(