Skip to content

Commit

Permalink
Adds linting of YAML files
Browse files Browse the repository at this point in the history
  • Loading branch information
funkyfuture committed Oct 13, 2024
1 parent aa6f0e6 commit 0c4b83c
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "monthly"
interval: "monthly"

...
6 changes: 5 additions & 1 deletion .github/workflows/linkcheck.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
---

name: Check documentation's hyperlinks

on:

Check warning on line 5 in .github/workflows/linkcheck.yml

View workflow job for this annotation

GitHub Actions / other-quality-checks (lint)

5:1 [truthy] truthy value should be one of [false, true]
Expand All @@ -11,6 +13,8 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.x"
python-version: "3.x"
- run: pipx install hatch
- run: hatch run docs:linkcheck

...
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---

name: Publish delb
on: # yamllint disable-line
on:

Check warning on line 4 in .github/workflows/publish.yml

View workflow job for this annotation

GitHub Actions / other-quality-checks (lint)

4:1 [truthy] truthy value should be one of [false, true]
push:
tags: ["*"]

Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/quality-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ jobs:
build:
runs-on: ubuntu-latest
outputs:
python-versions: ${{ steps.baipp.outputs.supported_python_classifiers_json_array }}
python-versions: >-
${{ steps.baipp.outputs.supported_python_classifiers_json_array }}
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -81,8 +82,8 @@ jobs:
strategy:
matrix:
target:
- code-lint
- doctest
- lint
- mypy
steps:
- uses: actions/checkout@v4
Expand Down
11 changes: 6 additions & 5 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,6 @@ black:
coverage-report:
hatch run unit-tests:coverage-report

# code linting with flake8
code-lint:
hatch run linting:check

# generate Sphinx HTML documentation, including API docs
docs:
hatch run docs:clean
Expand All @@ -34,6 +30,11 @@ doctest:
hatch run docs:clean
hatch run docs:doctest

# code & data linting with flake8 & yamllint
lint:
hatch run linting:check
pipx run yamllint $(find . -name "*.yaml" -or -name "*.yml")

# run static type checks with mypy
mypy:
hatch run mypy:check
Expand All @@ -60,7 +61,7 @@ show-docs: docs
xdg-open docs/build/html/index.html

# run all tests on normalized code
tests: black code-lint mypy pytest doctest
tests: black lint mypy pytest doctest

# run the testsuite against a wheel (installed from $WHEEL_PATH); intended to run on a CI platform
test-wheel $WHEEL_PATH:
Expand Down

0 comments on commit 0c4b83c

Please sign in to comment.