ci: prek linters, lint and test workflows #7
Loading…
Reference in a new issue
No description provided.
Delete branch "prek-linters"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Lint and test in one place, locally and in CI.
.pre-commit-config.yaml, pinned; Renovate's pre-commit manager keeps them current): pre-commit-hooks basics, shellcheck, shfmt, hadolint, yamllint, actionlint, markdownlint-cli2, editorconfig-checker. All ship Python/Node-packaged tools: no Docker-image hooks (bind mounts don't resolve inside DinD jobs) and no system hooks..editorconfig(LF, UTF-8, final newline, 2-space indent including*.sh; Markdown indentation unset so tab-indented shell samples indocs/stay valid),.yamllint.yml(document-start off, line length 160,on:keys allowed, one space before comments),.markdownlint-cli2.jsonc(no line length, tabs allowed in code blocks).git diff -wshows only the splitbad()helpers); 14 missing blank lines before lists and one table separator fixed indocs/.lintworkflow: every push and PR; installs a checksum-verified prek 0.5.3 into a temp dir on$GITHUB_PATH(no root needed), runs every hook.testworkflow: only whenDockerfile,entrypoint.sh,healthcheck.sh,compose.yaml,tests/**or the workflow change; PyYAML in a venv, then both test scripts against the runner's DinD.tests/entrypoint.test.shnames its image and container per run (RUN_IDfrom/dev/urandom) and removes them in anEXITtrap, so concurrent jobs on one runner's shared daemon don't collide.prek install,prek run --all-files, the two workflows).Spec and plan:
docs/superpowers/specs/2026-09-27-prek-linters-design.md,docs/superpowers/plans/2026-09-27-prek-linters.md.Verification
prek run --all-filespasses; both test scripts pass after the re-indent.tests/entrypoint.test.shruns collided (conflict: unable to remove repository reference); after it, both pass and leave nocoolify-forgejo-runner:test-*images orcfr-entrypoint-test-*containers, including after an early exit.lintandtestgreen for6efeffd; the docs-only pushf181095ranlintonly (green) and notest./usr/local/binon a runner still on the non-root image; the install no longer needs root.