File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : HACS Validation
2+
3+ on :
4+ push :
5+ branches : [master]
6+ pull_request :
7+ schedule :
8+ - cron : " 0 0 * * *"
9+
10+ jobs :
11+ validate :
12+ runs-on : ubuntu-latest
13+ steps :
14+ - uses : actions/checkout@v4
15+ - uses : hacs/action@main
16+ with :
17+ category : integration
Original file line number Diff line number Diff line change 1+ name : Pre-commit
2+
3+ on :
4+ push :
5+ branches : [master]
6+ pull_request :
7+
8+ jobs :
9+ pre-commit :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v4
13+ - uses : actions/setup-python@v5
14+ with :
15+ python-version : " 3.13"
16+ - uses : pre-commit/action@v3.0.1
Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ release :
5+ types : [published]
6+
7+ jobs :
8+ release :
9+ runs-on : ubuntu-latest
10+ steps :
11+ - uses : actions/checkout@v4
12+ - name : Validate version matches release tag
13+ run : |
14+ version=$(python3 -c "import json; print(json.load(open('custom_components/cpu_capacity/manifest.json'))['version'])")
15+ tag="${GITHUB_REF#refs/tags/v}"
16+ if [ "$version" != "$tag" ]; then
17+ echo "manifest.json version ($version) does not match release tag ($tag)"
18+ exit 1
19+ fi
You can’t perform that action at this time.
0 commit comments