-
Notifications
You must be signed in to change notification settings - Fork 3
50 lines (47 loc) · 1.33 KB
/
push-pull.yaml
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
name: Checks and release
on:
push:
pull_request:
jobs:
hassfest: # https://developers.home-assistant.io/blog/2020/04/16/hassfest
name: "Hassfest Validation"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout the repository"
uses: "actions/checkout@v4"
- name: "Run hassfest validation"
uses: "home-assistant/actions/hassfest@master"
hacs: # https://github.com/hacs/action
name: "HACS Validation"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout the repository"
uses: "actions/checkout@v4"
- name: "Run HACS validation"
uses: "hacs/action@main"
with:
category: "integration"
ignore: "brands"
style:
runs-on: "ubuntu-latest"
name: Check style formatting
steps:
- uses: "actions/checkout@v4"
- uses: "actions/setup-python@v4"
with:
python-version: "3.x"
- run: python3 -m pip install black
- run: black .
release:
needs: [hassfest, hacs, style]
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4
- uses: CupOfTea696/gh-action-auto-release@v1.0.2
with:
title: "Release: $version"
tag: "v$semver"
draft: false
regex: "/^Release: #{semver}$/i"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}