Skip to content

docs

docs #13

Workflow file for this run

name: "docs"
on:
workflow_dispatch:
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
jobs:
docs:
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v3
- name: Setup
uses: ./.github/actions/setup
- name: Checkout Docs Repository
uses: actions/checkout@v3
with:
repository: dl-solarity/docs
ssh-key: ${{ secrets.DOCS_DEPLOY_KEY }}
path: docs
- name: Generate and Copy Docs
run: |
npx hardhat markup --outdir markups
rm -rf markups/contracts/mock
rm -rf markups/contracts/interfaces
rm -rf docs/docs/reference/contracts
mkdir -p docs/docs/reference
cp -r markups/contracts docs/docs/reference
- name: Push Docs
run: |
git config --global user.name "Docs Syncer"
git config --global user.email "[email protected]"
git fetch --unshallow
latest_tag=$(git describe --tags --abbrev=0)
cd docs
git add -f .
if ! git diff-index --quiet HEAD; then
git commit -m "CI: \`$latest_tag\`"
git push
fi