Skip to content

Commit

Permalink
build(ci): improve PR process (#1015)
Browse files Browse the repository at this point in the history
<!-- < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < ☺
v                               ✰  Thanks for creating a PR! ✰
v    Before smashing the submit button please review the checkboxes.
v If a checkbox is n/a - please still include it but + a little note why
☺ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >  -->

## Description

This PR improves the overall PR creation and checking process.
Particularly it includes the following changes:
- improved the `PULL_REQUEST_TEMPLATE` to have more meaningful
checkboxes that the author needs to check
- added a GitHub workflow to make sure that PR titles follow the
[Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/)
specification


## Checklist
- [ ] Ran Linting
- [ ] Targeted PR against correct branch.
- [ ] Linked to Github issue with discussion and accepted design OR link
to spec that describes this work.
- [ ] Wrote unit tests.
- [ ] Added an entry to the `CHANGELOG.md` file.
- [ ] Re-reviewed `Files changed` in the Github PR explorer.
  • Loading branch information
RiccardoM committed Oct 5, 2022
1 parent 119eaba commit 9125601
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 17 deletions.
24 changes: 24 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
## Description

Closes: #XXXX

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [ ] ran linting
- [ ] wrote tests where necessary
- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] targeted the correct branch
- [ ] provided a link to the relevant issue or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed
- [ ] added an entry to the `CHANGELOG.md` file
17 changes: 0 additions & 17 deletions .github/pull_request_template.md

This file was deleted.

20 changes: 20 additions & 0 deletions .github/workflows/lint-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: "Lint PR"
# Lint PR workflow runs linting over a single PR in order to make sure that the title respects
# the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) specification.
# This workflow is run every time a PR is opened, edited or updated somehow.

on:
pull_request_target:
types:
- opened
- edited
- synchronize

jobs:
Lint:
runs-on: ubuntu-latest
steps:
- name: Run lint ✅
uses: amannn/action-semantic-pull-request@v4.5.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 9125601

Please sign in to comment.