name: Documentation on: push jobs: build: runs-on: ubuntu-18.04 steps: - uses: actions/checkout@v2 with: submodules: true fetch-depth: 0 - name: Install Zola run: ./scripts/ci.sh install - name: Build production website run: ./scripts/ci.sh build - name: Deploy to gh-pages 🚀 if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} uses: JamesIves/github-pages-deploy-action@4.1.4 with: branch: gh-pages token: ${{ secrets.GITHUB_TOKEN }} folder: ./public - name: deploy if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && github.repository == 'forgeflux-org/docs' }} run: >- curl --location --request POST "https://deploy.batsense.net/api/v1/update" --header 'Content-Type: application/json' --data-raw "{ \"secret\": \"${{ secrets.DEPLOY_TOKEN }}\", \"branch\": \"gh-pages\" }"