Skip to content

add --no-power-off to flashers #439

add --no-power-off to flashers

add --no-power-off to flashers #439

Workflow file for this run

name: Linters
on:
workflow_dispatch:
push:
branches:
- main
- 'release-*'
pull_request:
merge_group:
permissions:
contents: read
pull-requests: read
jobs:
# Detect which paths changed to conditionally run linters
changes:
runs-on: ubuntu-latest
outputs:
controller: ${{ steps.filter.outputs.controller }}
helm: ${{ steps.filter.outputs.helm }}
protocol: ${{ steps.filter.outputs.protocol }}
python: ${{ steps.filter.outputs.python }}
steps:
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
controller:
- 'controller/**'
- '.github/workflows/lint.yaml'
helm:
- 'controller/deploy/helm/**'
- '.github/workflow/lint.yaml'
protocol:
- 'protocol/**'
- '.github/workflows/lint.yaml'
python:
- 'python/**'
- '.github/workflows/lint.yaml'
lint-go:
needs: changes
if: needs.changes.outputs.controller == 'true'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.24'
- name: Run go linter
working-directory: controller
run: make lint
lint-helm:
needs: changes
if: needs.changes.outputs.helm == 'true'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Run helm linter
working-directory: controller
run: make lint-helm
lint-protobuf:
needs: changes
if: needs.changes.outputs.protocol == 'true'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Run protobuf linter
working-directory: protocol
run: make lint
lint-python:
needs: changes
if: needs.changes.outputs.python == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run ruff
uses: astral-sh/ruff-action@4919ec5cf1f49eff0871dbcea0da843445b837e6 # v3.6.1
with:
src: './python'
version-file: python/pyproject.toml
typos:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run typos
uses: crate-ci/typos@a1d64977b4aa1709d6328d518aa753f4899352d8 # v1.42.2
with:
config: ./typos.toml