Refactor subprocess call and print statement

Updated subprocess command to use list format and modified print statement for clarity.
This commit is contained in:
Hatvani Tamás
2025-11-09 14:55:23 +01:00
committed by GitHub
parent 1bf4d875af
commit 7cd4bb6b09

View File

@@ -29,8 +29,8 @@ jobs:
creds = json.load(open("service_account.json"))
gc = gspread.service_account_from_dict(creds)
sh = gc.open_by_key("${{ secrets.SPREADSHEET_ID }}")
v = subprocess.run(['git rev-parse --show-toplevel'], capture_output=True).stdout.decode()
print(v)
v = subprocess.run(['git','rev-parse','--show-toplevel'], capture_output=True).stdout.strip()
print(f"{v}/test_data.log")
with open(f"{v}/test_data.log", "r") as f:
lines = [line.strip() for line in f if line.strip()]