Port updater of docs.znc.in from travis to github actions

This commit is contained in:
Alexey Sokolov
2021-07-03 01:01:41 +01:00
parent 01877fcb0f
commit 8be5e4ce62
4 changed files with 25 additions and 4 deletions
@@ -7,7 +7,7 @@ doxygen
cd "$HOME"
git clone --depth=1 --branch=gh-pages github:znc/docs.git gh-pages || exit 1
cd "$TRAVIS_BUILD_DIR/doc/html/"
cd "$GITHUB_WORKSPACE/doc/html/"
mv ~/gh-pages/.git ./
echo docs.znc.in > CNAME
git add -A
@@ -28,9 +28,9 @@ if [[ ! -f ~/docs_need_commit ]]; then
fi
git commit -F- <<EOF
Latest docs on successful travis build $TRAVIS_BUILD_NUMBER
Latest docs on successful CI build $GITHUB_RUN_NUMBER
ZNC commit $TRAVIS_COMMIT
ZNC commit $GITHUB_SHA
EOF
git push origin gh-pages
View File
+22 -1
View File
@@ -100,7 +100,7 @@ jobs:
docker:
name: Docker push
runs-on: ubuntu-latest
if: github.event_name != 'pull_request'
if: github.event_name == 'push'
needs:
- gcc
- tarball
@@ -138,3 +138,24 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
build-args: |
VERSION_EXTRA=+docker-git-
docs:
name: Docs push
runs-on: ubuntu-latest
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
steps:
- uses: actions/checkout@v2
with:
submodules: true
- run: sudo apt-get update
- run: sudo apt-get install -y doxygen graphviz python3-yaml
- run: echo "$KEY" > ~/znc-github-key
env:
KEY: ${{ secrets.SSH_GITHUB_KEY_FOR_CI_BOT }}
- run: chmod 0600 ~/znc-github-key
- run: mkdir -p ~/.ssh
- run: cp .ci/ssh-config ~/.ssh/config
# It's not travis anymore, but oh well. TODO: fix
- run: git config --global user.email "travis-ci@znc.in"
- run: git config --global user.name "znc-travis"
- run: .ci/generate-docs.sh
Binary file not shown.