commitlint.yml 821 B

123456789101112131415161718192021222324
  1. name: "Commit Linter"
  2. on:
  3. # Only pull_request and push honor [skip ci]. Since this workflow must pass
  4. # to merge a PR, it can't be skipped, so use pull_request_target
  5. pull_request_target:
  6. types: [opened, synchronize, reopened, ready_for_review]
  7. branches:
  8. - 'master'
  9. jobs:
  10. lint-commits:
  11. runs-on: ubuntu-latest
  12. if: github.event.pull_request.draft == false
  13. steps:
  14. - uses: actions/checkout@v2
  15. with:
  16. fetch-depth: 0
  17. ref: ${{ github.event.pull_request.head.sha }}
  18. path: pr_nvim
  19. - uses: rhysd/action-setup-vim@v1
  20. with:
  21. neovim: true
  22. - run: wget https://raw.githubusercontent.com/neovim/neovim/master/scripts/lintcommit.lua
  23. - run: nvim --clean -es +"cd pr_nvim" +"lua dofile('../lintcommit.lua').main({trace=true})"