13 runs-on: ubuntu-latest
17 uses: actions/checkout@v2
20 run: sudo apt install mandoc
22 - name: Manual generation
25 sed -e "s/VERSION/$(git describe --always)/" ${PROJECT}.1 | \
26 mandoc -W warning -T utf8 -T html -O man=%N.%S.html -O style=mandoc.css 1> \
27 "man/${PROJECT}.1.html" || true
28 wget 'https://cvsweb.bsd.lv/~checkout~/mandoc/mandoc.css?rev=1.46&content-type=text/plain' -O man/mandoc.css
29 ln -sf "${PROJECT}.1.html" man/index.html
33 DEPLOY_TOKEN: ${{ secrets.GIT_DEPLOY_TOKEN }}
35 git clone --depth=1 --single-branch --branch gh-pages "https://x-access-token:${DEPLOY_TOKEN}@github.com/${GITHUB_REPOSITORY}.git" /tmp/gh-pages
36 git config --global user.name "${GITHUB_ACTOR}"
37 git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
38 mkdir -p /tmp/gh-pages/man
39 rm -f /tmp/gh-pages/man/*
40 cp -av man/*.html /tmp/gh-pages/man/
41 cp -av man/*.css /tmp/gh-pages/man/
43 git add -A && git commit --allow-empty -am "Publishing from ${GITHUB_REPOSITORY} ${GITHUB_SHA}"
44 git push origin gh-pages