Skip to content

finleyfamily/workflows

Repository files navigation

workflows

pre-commit renovate license

🤖 GitHub Action Workflows.

Table Of Contents

Home Assistant Add-on

Workflows for Home Assistant add-ons.

Inspired by hassio-addons/workflows.

CI

name: CI

on:
  pull_request:
  push:
    branches:
      - master
  workflow_dispatch:

jobs:
  workflows:
    permissions:
      pull-requests: read
    uses: finleyfamily/workflows/.github/workflows/hass-addon.ci.yml@master
    with:
      slug: ${{ github.event.repository.name }}

Deploy

Deploy add-on to repositories.

name: Deploy

on:
  release:
    types:
      - published
  workflow_run:
    workflows:
      - CI
    branches:
      - master
    types:
      - completed

jobs:
  workflows:
    uses: finleyfamily/workflows/.github/workflows/hass-addon.deploy.yml@master
    secrets:
      app-private-key: ${{ secrets.FINLEY_APP_PRIVATE_KEY }}
    with:
      slug: ${{ github.event.repository.name }}

Home Assistant Repository

Workflows for Home Assistant repositories.

Inspired by hassio-addons/workflows.

CI

name: CI

on:
  pull_request:
  push:
    branches:
      - master

jobs:
  workflows:
    uses: finleyfamily/workflows/.github/workflows/hass-repository.ci.yml@master

Repository Updater

Triggered from individual add-on repos to update to main add-on repository.

name: Repository Updater

# yamllint disable-line rule:truthy
on:
  push:
    branches:
      - master
    paths:
      - .github/workflows/repository-updater.yml
  repository_dispatch:
    types: ["update"]

jobs:
  workflows:
    uses: finleyfamily/workflows/.github/workflows/hass-repository.updater.yml@master
    secrets:
      UPDATER_TOKEN: ${{ secrets.HASS_UPDATER_TOKEN }}

pull_request_target

  • Assigns the author of a pull request to the pull request.
  • Enforce a branch naming convention.
  • Apply labels to PR.
name: pull_request_target

on:
  pull_request_target:

jobs:
  workflows:
    permissions:
      contents: write
      pull-requests: write
    uses: finleyfamily/workflows/.github/workflows/pull_request_target.yml@master

Python (build)

Build python package and upload distributable as an artifact of the job.

on:
  pull_request:
  push:
    branches:
      - master

jobs:
  python-build:
    uses: finleyfamily/workflows/.github/workflows/python.build.yml@master

Inputs

For a list of inputs with default values, descriptions, and types, see python.build.yml

Python (checks)

Lint and test python code.

on:
  pull_request:
  push:
    branches:
      - master

jobs:
  python-checks:
    strategy:
      matrix:
        python-version: [3.11, 3.12]
    uses: finleyfamily/workflows/.github/workflows/python.checks.yml@master
    with:
      node-version: '20'
      python-version: ${{ matrix.python-version }}

Inputs

For a list of inputs with default values, descriptions, and types, see python.checks.yml

Release Drafter

Drafts releases based on pull requests.

on:
  push:
    # branches to consider in the event; optional, defaults to all
    branches:
      - master

jobs:
  release-drafter:
    permissions:
      contents: write
    uses: finleyfamily/workflows/.github/workflows/release-drafter.yml@master

Spellcheck

Uses cspell to check spelling within a project.

on:
  pull_request:  # any pull request
  push:
    branches:
      - master

jobs:
  spellcheck:
    uses: finleyfamily/workflows/.github/workflows/spellcheck.yml@master
    with:
      node-version: '20'

Prerequisites

  • setup-npm target in Makefile to install node dependencies
  • spellcheck target in Makefile to run cspell

Inputs

For a list of inputs with default values, descriptions, and types, see spellcheck.yml

Releases

No releases published

Contributors 3

  •  
  •  
  •