Skip to content

Commit e7efabd

Browse files
feat: switch documentation deployment to 'doc' branch
1 parent 6643378 commit e7efabd

3 files changed

Lines changed: 23 additions & 13 deletions

File tree

.github/scripts/prepare_doxygen.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ project_name="$(head -n 1 README.md | sed 's/#//')"
77
repository_name=$(git rev-parse --show-toplevel | xargs basename)
88

99
echo "Clone $repository_name..."
10-
git clone --branch gh-pages https://github.com/eclipse/"$repository_name".git
10+
git clone --branch doc https://github.com/eclipse/"$repository_name".git
1111

1212
cd "$repository_name" || exit
1313

.github/workflows/publish-doc-release.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,14 @@ jobs:
2828
- name: Prepare Doxygen doc page locally
2929
working-directory: .
3030
run: ./.github/scripts/prepare_doxygen.sh ${{ env.PROJECT_VERSION }}
31-
- name: Deploy Doxygen documentation to gh-pages
32-
uses: peaceiris/actions-gh-pages@v3
33-
with:
34-
github_token: ${{ secrets.GITHUB_TOKEN }}
35-
publish_dir: ./${{ github.event.repository.name }}
36-
enable_jekyll: true
31+
- name: Deploy to doc branch
32+
run: |
33+
git config --global user.name "Eclipse Keypop Bot"
34+
git config --global user.email "${{ github.repository }}-bot@eclipse.org"
35+
cd ${{ github.event.repository.name }}
36+
git remote set-url origin "https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
37+
git add .
38+
git commit -m "docs: update ${{ github.event.inputs.version || github.ref_name }} documentation"
39+
git push origin doc --force
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/publish-doc-snapshot.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,14 @@ jobs:
3131
- name: Prepare Doxygen doc page locally
3232
working-directory: .
3333
run: ./.github/scripts/prepare_doxygen.sh ${{ env.PROJECT_VERSION }}
34-
- name: Deploy Doxygen documentation to gh-pages
35-
uses: peaceiris/actions-gh-pages@v3
36-
with:
37-
github_token: ${{ secrets.GITHUB_TOKEN }}
38-
publish_dir: ./${{ github.event.repository.name }}
39-
enable_jekyll: true
34+
- name: Deploy to doc branch
35+
run: |
36+
git config --global user.name "Eclipse Keypop Bot"
37+
git config --global user.email "${{ github.repository }}-bot@eclipse.org"
38+
cd ${{ github.event.repository.name }}
39+
git remote set-url origin "https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
40+
git add .
41+
git commit -m "docs: update snapshot documentation"
42+
git push origin doc --force
43+
env:
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)