hass.tibber_prices/scripts/lint
Julian Pawlowski b2d63c2b6d chore(scripts): add explicit format/fix/check modes for all file types
Split lint workflow into three clearly separated modes:

- scripts/format: Python-only formatting (Ruff format)
- scripts/lint-fix: Python-only lint auto-fixes (Ruff check --fix)
- scripts/lint: convenience wrapper (delegates to format + lint-fix)

Add all-in-one scripts covering Python and non-Python files (Prettier for
JSON/JSONC/Markdown/YAML, shfmt for shell scripts):

- scripts/format-all: format all file types
- scripts/check-all: check-only for all file types (CI/CD parity)
- scripts/lint-all: format-all + lint-fix in one command

Release-Notes: skip
User-Impact: none
2026-04-12 12:11:38 +00:00

21 lines
449 B
Bash
Executable file

#!/bin/bash
# script/lint: Run format and lint-fix in one command
#
# Convenience wrapper that runs scripts/format and scripts/lint-fix in sequence.
# This preserves the previous behavior while exposing explicit 3-mode workflows:
# check, fix, and format.
#
# Usage:
# ./scripts/lint
#
# Examples:
# ./scripts/lint
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
cd "$SCRIPT_DIR/.."
"$SCRIPT_DIR/format"
"$SCRIPT_DIR/lint-fix"