Skip to content

Commit 8fbbdca

Browse files
committed
ci: fix access to enginiro repos
1 parent 533f876 commit 8fbbdca

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

.github/workflows/pages.yml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,19 @@ jobs:
66
build:
77
runs-on: ubuntu-latest
88
steps:
9-
- uses: actions/checkout@v3
10-
- uses: webfactory/ssh-agent@v0.7.0
11-
with:
12-
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
9+
- uses: actions/checkout@v4
1310
- uses: shivammathur/setup-php@v2
1411
with:
15-
php-version: '7.4'
16-
- uses: actions/setup-node@v3
12+
php-version: '8.1'
13+
- uses: actions/setup-node@v4
1714
with:
18-
node-version: 18
15+
node-version: 22
1916
- run: npm install
2017
- run: ./build.sh
18+
env:
19+
GH_ENGINIRO_TOKEN: ${{ secrets.GH_ENGINIRO_TOKEN }}
2120
- run: touch build/site/.nojekyll
22-
- uses: actions/upload-pages-artifact@v1
21+
- uses: actions/upload-pages-artifact@v3
2322
with:
2423
path: build/site/
2524
deploy:
@@ -32,4 +31,4 @@ jobs:
3231
url: ${{ steps.deployment.outputs.page_url }}
3332
runs-on: ubuntu-latest
3433
steps:
35-
- uses: actions/deploy-pages@v1
34+
- uses: actions/deploy-pages@v4

build.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ while read -r repository; do
2626
git pull
2727
cd ../
2828
else
29+
if [ "$GH_ENGINIRO_TOKEN" != "" ]; then
30+
repository="$(echo "$repository" | sed "s%git@github.com:enginiro/%https://enginiro:$GH_ENGINIRO_TOKEN@github.com/enginiro/%")"
31+
fi
32+
2933
git clone --depth 1 "$repository" --branch "main" --single-branch
3034
fi
3135

0 commit comments

Comments
 (0)