Skip to content

Commit c654d91

Browse files
committed
fix github action
1 parent d7ce201 commit c654d91

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

‎.github/workflows/build.yml‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ concurrency:
1414
jobs:
1515
build:
1616
runs-on: ubuntu-latest
17+
permissions:
18+
contents: write
1719
steps:
1820
- uses: actions/checkout@v6
1921
with:
@@ -148,9 +150,9 @@ jobs:
148150
-Dsonar.coverageReportPaths=build/coverage.xml
149151
150152
- name: Build and deploy documentation
151-
if: github.ref == 'refs/heads/main' && env.TOKEN_GITHUB != ''
153+
if: github.ref == 'refs/heads/main'
152154
env:
153-
TOKEN_GITHUB: ${{ secrets.TOKEN_GITHUB }}
155+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
154156
run: |
155157
cd doc
156158
LC_ALL=C.UTF-8 ./Build.sh
@@ -159,7 +161,7 @@ jobs:
159161
cd ..
160162
git config --global user.email "actions@github.com"
161163
git config --global user.name "GitHub Actions"
162-
git clone -b gh-pages https://${TOKEN_GITHUB}@github.com/simgrid/DTLMod.git gh-pages
164+
git clone -b gh-pages https://x-access-token:${GH_TOKEN}@github.com/simgrid/DTLMod.git gh-pages
163165
cd gh-pages
164166
cp -Rf $HOME/gh-pages-to-deploy/* .
165167
touch .nojekyll

0 commit comments

Comments
 (0)