-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (47 loc) · 1.65 KB
/
check_build.yml
File metadata and controls
51 lines (47 loc) · 1.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Checks
on:
pull_request:
branches:
- main
jobs:
lint-commits:
name: Lint commits
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
# we actually need "github.event.pull_request.commits + 1" commit
fetch-depth: 0
- name: Volta
uses: volta-cli/action@v4
- run: npm ci
- run: npx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose
check:
name: Check build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Volta
uses: volta-cli/action@v4
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- name: Generate release notes preview
id: build-release-notes
uses: guilhermetod/semantic-release-notes-preview@v1.0.0
- name: Comment release notes preview
if: steps.build-release-notes.outputs.releaseNotes
uses: peter-evans/create-or-update-comment@v1
with:
issue-number: ${{ github.event.number }}
body: |
## 👋 Hey there!
Thank you for you contribution. Below is a preview of the release notes if your PR gets merged.
Please, make sure it includes all your significant changes with descriptive messages.
Keep in mind that release notes are automatically generated from the commit messages according to [conventional commits](https://www.conventionalcommits.org/).
---
${{ steps.build-release-notes.outputs.releaseNotes }}