name: Deploy Documentation

on:
  push:
    branches:
      - master
    paths:
      - docs/README.md
      - docs/config.json
  release:
    types:
      - published
      - unpublished
      - deleted
jobs:
  trigger-doc-build:
    runs-on: ubuntu-latest
    steps:
      - name: Install HTTPie
        run: sudo pip install httpie
      - name: Trigger new documentation build
        run: http --ignore-stdin POST ${{ secrets.DOCS_UPDATE_VERCEL_HOOK }}
