Skip to main content

GitHub Actions Codecov Renovate
GitHub Release PyPI TestPyPI NPM
Go Python Node

Stylebook

The Stylebook logo.

Linter aggregator for various data formats. All linters are preconfigured with common rules like duplicate blank lines, trailing whitespace and consistent indentation. In Markdown, it has third-party rules to check dead links and broken images.

Runner File type Linter
Go CSV csvlint with
RFC 4180
Dockerfile Hadolint with
Docker Build Best Practices
GitHub Actions actionlint
Go Module gomoddirectives
Kubernetes kube-linter
LaTeX ChkTeX
Makefile checkmake
Properties propertieslint
Protobuf protolint with
Protobuf Style Guide
Shell ShellCheck
Terraform TFLint with
Terraform Style Guide
XML libxml2
Python Ansible ansible-lint
AsciiDoc AsciiDoc-Linter
AWS CloudFormation CloudFormation Linter
Batch Blinter
Dotenv dotenv-linter
INI PyINILint
reStructuredText restructuredtext-lint
SQL SQLFluff with
Mozilla SQL Style Guide
TOML Taplo with
TOML Quick Tour
YAML yamllint with
YAML Best Practices
Node Amazon State Language asl-validator
CSS Stylelint with
Mozilla CSS Coding Guide
GraphQL graphql-schema-linter
HTML HTMLHint with
Mozilla HTML Style Guide
JSON JSON Lint
Lockfile lockfile-lint
Markdown markdownlint with
Adobe Markdown Basics
Mermaid Maid
Tekton tekton-lint

View rules

Download

Several linters must be installed separatedly, preferably at OS level:

  • ChkTeX
  • Hadolint
  • ShellCheck
  • libxml2

Go

Most linters are brought in as dependencies, others can be installed selectively.

go install github.com/hanggrian/stylebook@latest
go install github.com/checkmake/checkmake/cmd/checkmake@latest
go install github.com/terraform-linters/tflint@latest

PyPI

All linters are brought in as optional dependencies, exclude the ones you don't need.

pip install "stylebook[ \
  ansible-lint, \
  asciidoc-linter, \
  blinter, \
  cfn-lint, \
  dotenv-linter, \
  pyinilint, \
  sqlfluff, \
  taplo, \
  yamllint, \
  restructuredtext-lint \
]"

NPM

Most linters are brought in as optional dependencies, except for Stylelint, which needs to be installed in the root package.json.

npm i @hanggrian/stylebook \
  stylelint \
  @stylistic/stylelint-plugin \
  stylelint-config-recommended --save-dev

Usage

CLI screenshot

Insert target paths into the command. The program will recursively search for qualifying file types and spawn the corresponding linter processes.

stylebook . # Go binary
npx @hanggrian/stylebook some-folder/ some-file.sql
source .venv/bin/activate && stylebook **/*

Configuration

Configuration files are automatically picked up. If the file doesn't exist, the program will use default configuration. If .stylebookrc exists in the root project directory, it will be used as exclusion list.

Metadata

Release files for stylebook 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for stylebook 0.3.0
File Size Uploaded Provenance Actions
stylebook-0.3.0.tar.gz 10.4 kB Without provenance Details for stylebook-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for stylebook 0.3.0
File Interpreter ABI Platform Actions
stylebook-0.3.0-py3-none-any.whl Python 3 none any Details for stylebook-0.3.0-py3-none-any.whl

Total release size: 27.3 kB

Release files / stylebook-0.3.0.tar.gz

Download URL stylebook-0.3.0.tar.gz
Size 10.4 kB
Tags Source
SHA-256 checksum
How to use checksums
34bce952bf5cf49c6a3760bd455921bbf529246e4431af5febbd3bdf48c1bb47
BLAKE2b-256 checksum
How to use checksums
59c90655c024a3fd6e8c5e5c87caec6ee3b54772b3a96d6781978a901537259c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.0

Release files / stylebook-0.3.0-py3-none-any.whl

Download URL stylebook-0.3.0-py3-none-any.whl
Size 17.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4385337f3442b0b30e3af5cc2f4ff58231cd542cdf31b889ce1c8eef9226b623
BLAKE2b-256 checksum
How to use checksums
7fea5663832e449860e37a3dc58ace03fc9050208eef98dfcdf12071d21ae687
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.0

Security for stylebook 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page