name: Verify Package Version

on:
  pull_request:
    types: [opened, edited, reopened, synchronize, ready_for_review]

jobs:
  verify:
    runs-on: ubuntu-latest
    if: contains(github.event.pull_request.title, 'changelog') || contains(github.event.pull_request.title, 'release')
    steps:
      - uses: actions/checkout@v2
      - name: verify-version
        uses: actions-cool/verify-package-version@v1
        with:
          title-include-content: 'docs'
          title-include-version: true
          open-comment: true
