Skip to content

Commit 613631a

Browse files
committed
Fix workflow credentials.
Update action versions.
1 parent 1a091d3 commit 613631a

2 files changed

Lines changed: 17 additions & 9 deletions

File tree

.github/workflows/cache.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ jobs:
2121
run: |
2222
echo "TIMESTAMP=$(date -u +"%F-%H")" >> "$GITHUB_ENV"
2323
- name: Checkout
24-
uses: actions/checkout@v4
24+
uses: actions/checkout@v6
2525
with:
2626
path: ${{ env.REPO_DIR }}
2727
token: ${{ secrets.GITHUB_TOKEN }}
2828
- name: Setup python
29-
uses: actions/setup-python@v5
29+
uses: actions/setup-python@v6
3030
with:
3131
python-version: "3.11"
3232
cache: "pip"
@@ -46,7 +46,7 @@ jobs:
4646
echo "Limit Reached: $(grep -c 'rate limit exceeded' ${{ env.REPO_DIR }}/_visualize/LAST_CACHE_REQUEST.log)"
4747
- name: Save log files
4848
if: ${{ always() }}
49-
uses: actions/upload-artifact@v4
49+
uses: actions/upload-artifact@v6
5050
with:
5151
name: logfiles_${{ env.TIMESTAMP }}_cache
5252
path: |

.github/workflows/update.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,22 +21,23 @@ jobs:
2121
run: |
2222
echo "TIMESTAMP=$(date -u +"%F-%H")" >> "$GITHUB_ENV"
2323
- name: Checkout
24-
uses: actions/checkout@v4
24+
uses: actions/checkout@v6
2525
with:
2626
path: ${{ env.REPO_DIR }}
2727
token: ${{ secrets.GITHUB_TOKEN }}
28+
persist-credentials: false
2829
- name: Setup python
29-
uses: actions/setup-python@v5
30+
uses: actions/setup-python@v6
3031
with:
3132
python-version: "3.11"
3233
cache: "pip"
3334
cache-dependency-path: "${{ env.REPO_DIR }}/_visualize/scripts/requirements.txt"
3435
- name: Install dependencies
3536
run: pip install -r ${{ env.REPO_DIR }}/_visualize/scripts/requirements.txt
3637
- name: Run update script
37-
run: ./${{ env.REPO_DIR }}/.github/scripts/update.sh
3838
env:
3939
GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
40+
run: ./${{ env.REPO_DIR }}/.github/scripts/update.sh
4041
- name: Create GitHub App Installation Token
4142
uses: actions/create-github-app-token@v2
4243
id: app-token
@@ -45,14 +46,21 @@ jobs:
4546
private-key: ${{ secrets.PRIVATE_KEY }}
4647
- name: Get GitHub App User ID
4748
id: get-user-id
49+
env:
50+
GH_TOKEN: ${{ steps.app-token.outputs.token }}
4851
run: echo "user-id=$(gh api "/users/${{ steps.app-token.outputs.app-slug }}[bot]" --jq .id)" >> "$GITHUB_OUTPUT"
52+
- name: Configure git
4953
env:
5054
GH_TOKEN: ${{ steps.app-token.outputs.token }}
55+
run: |
56+
gh auth setup-git
57+
git config --global user.name '${{ steps.app-token.outputs.app-slug }}[bot]'
58+
git config --global user.email '${{ steps.get-user-id.outputs.user-id }}+${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com'
5159
- name: Commit updated data
60+
env:
61+
GH_TOKEN: ${{ steps.app-token.outputs.token }}
5262
run: |
5363
pushd ${{ env.REPO_DIR }}
54-
git config user.name '${{ steps.app-token.outputs.app-slug }}[bot]'
55-
git config user.email '${{ steps.get-user-id.outputs.user-id }}+${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com'
5664
git stash
5765
git pull --ff-only
5866
git stash pop
@@ -69,7 +77,7 @@ jobs:
6977
echo "Limit Reached: $(grep -c 'rate limit exceeded' ${{ env.REPO_DIR }}/_visualize/LAST_MASTER_UPDATE.log)"
7078
- name: Save log files
7179
if: ${{ always() }}
72-
uses: actions/upload-artifact@v4
80+
uses: actions/upload-artifact@v6
7381
with:
7482
name: logfiles_${{ env.TIMESTAMP }}_update
7583
path: |

0 commit comments

Comments
 (0)