Hassfest for custom components
Hassfest is an internal tool that we use in Home Assistant to make sure that all integrations have valid data. We've now made Hassfest able to validate any integration, including custom integrations. To make it easy to get started with this, @ludeeus has created a GitHub Action that gets you up and running in less than a minute.
To install it, follow these steps:
-
Go to your custom component repository on GitHub
-
Click on "Create new file"
-
For filename, paste
.github/workflows/hassfest.yaml
-
Paste the following contents:
name: Validate with hassfest
on:
push:
pull_request:
schedule:
- cron: "0 0 * * *"
jobs:
validate:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: home-assistant/actions/hassfest@master
GitHub will now lint all incoming PRs and commits with hassfest, and will also run it once every night to check against the latest requirements.
The Hassfest action will track the beta release channel. That way you will be notified if your integration is incompatible with newer versions of Home Assistant.