From 11d8ed26362d26387ab9803367917f7bc81ca6dc Mon Sep 17 00:00:00 2001 From: Chris Holdgraf Date: Tue, 17 Sep 2024 16:45:18 -0700 Subject: [PATCH] Add github token to action for sphinx build (#49) * Add github token to action for sphinx build * Add check --- .github/workflows/deploy.yml | 2 ++ book/people.md | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f29420a..35e450f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -73,6 +73,8 @@ jobs: run: sphinx-build -v -b dirhtml book book/_build/dirhtml env: AIRTABLE_API_KEY: ${{ secrets.AIRTABLE_API_KEY }} + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # Encrypt pages that are only meant for team consumption - name: Encrypt some pages diff --git a/book/people.md b/book/people.md index 5c5755d..8dda368 100644 --- a/book/people.md +++ b/book/people.md @@ -85,7 +85,10 @@ tags: [remove-cell] --- # Use the GH CLI to print all of the records in our time off table cmd = "gh project item-list 39 --owner 2i2c-org -L 500 --format json" -out = run(cmd.split(), text=True, capture_output=True) +try: + out = run(cmd.split(), text=True, capture_output=True, check=True) +except Exception: + raise ValueError(out.stderr) # Strip the output of all color codes and parse it as JSON, then a dataframe def strip_ansi(text):