diff --git a/.github/workflows/upload_data.yml b/.github/workflows/upload_data.yml index 6d9069c..3d6118b 100644 --- a/.github/workflows/upload_data.yml +++ b/.github/workflows/upload_data.yml @@ -23,14 +23,16 @@ jobs: echo "$GOOGLE_SERVICE_ACCOUNT_JSON" > service_account.json python <<'PYCODE' - import gspread, json, time + import gspread, json, time, subprocess # credentials 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) - with open("test_data.log", "r") as f: + with open(f"{v}/test_data.log", "r") as f: lines = [line.strip() for line in f if line.strip()] project = lines[0].lower()