Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality. Learn more →
Top 21 Python pre-commit Projects
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
pyupgrade
A tool (and pre-commit hook) to automatically upgrade syntax for newer versions of the language.
-
FastAPI-Backend-Template
A backend project template with FastAPI, PostgreSQL with asynchronous SQLAlchemy 2.0, Alembic for asynchronous database migration, and Docker. (by Aeternalis-Ingenium)
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
conventional-pre-commit
A pre-commit hook that checks commit messages for Conventional Commits formatting
-
check-jsonschema
A CLI and set of pre-commit hooks for jsonschema validation with built-in support for GitHub Workflows, Renovate, Azure Pipelines, and more!
-
cookiecutter-fastapi-backend
:cookie: Cookiecutter template to build and deploy fastapi backends..batteries included
-
pre-commit-config-shellcheck
Tool for checking entry points in the pre-commit config with ShellCheck.
-
version-checker
pre-commit hook: make sure your package doesn't refer to different versions of itself across the codebase ✅ (by jalvaradosegura)
-
black-pre-commit-example-setup
Example repo for article showing how to setup Black and pre-commit for text-formatting in python
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
Project mention: How to setup Black and pre-commit in python for auto text-formatting on commit | dev.to | 2024-03-29Today we are going to look at how to setup Black (a python code formatter) and pre-commit (a package for handling git hooks in python) to automatically format you code on commit.
Project mention: Implementing Quality Checks In Your Git Workflow With Hooks and pre-commit | dev.to | 2023-12-13# See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v3.2.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer - id: check-yaml - id: check-toml - id: check-added-large-files - repo: local hooks: - id: tox lint name: tox-validation entry: pdm run tox -e test,lint language: system files: ^src\/.+py$|pyproject.toml|^tests\/.+py$ types_or: [python, toml] pass_filenames: false - id: tox docs name: tox-docs language: system entry: pdm run tox -e docs types_or: [python, rst, toml] files: ^src\/.+py$|pyproject.toml|^docs\/ pass_filenames: false - repo: https://github.com/pdm-project/pdm rev: 2.10.4 # a PDM release exposing the hook hooks: - id: pdm-lock-check - repo: https://github.com/jumanjihouse/pre-commit-hooks rev: 3.0.0 hooks: - id: markdownlint
Project mention: A Tale of Two Kitchens - Hypermodernizing Your Python Code Base | dev.to | 2023-11-12pyupgrade and flynt are examples of tools that modify your code base from earlier python versions into the newest python syntax, rewriting all string formats into f-strings and similar things.
Project mention: Automate Python Linting and Code Style Enforcement with Ruff and GitHub Actions | dev.to | 2023-07-22
[[language]] name = "python" roots = ["pyproject.toml"] formatter = { command = "black", args = ["--quiet", "-"] } language-server = { command = "pyright-langserver", args = ["--stdio"] } config = {} auto-format = true [[language]] name = "rust" auto-format = true # [[language]] # name = "typescript" # auto-format = true # formatter = { command = "prettier", args = ["--parser", "typescript"]} # # pass format options according to https://github.com/typescript-language-server/typescript-language-server#workspacedidchangeconfiguration omitting the "[language].format." prefix. # config = { format = { "semicolons" = "insert", "insertSpaceBeforeFunctionParenthesis" = true } } [[language]] name = "tsx" formatter = { command = 'prettier', args = ["--parser", "typescript"] } auto-format = true [[language]] name = "javascript" auto-format = true formatter = { command = 'npx', args = ["prettier", "--config", ".prettierrc", "--parser", "javascript"] } # formatter = { command = "prettier", args = ["--parser", "javascript"]} [[language]] name = "css" formatter = { command = 'prettier', args = ["--parser", "css"] } [[language]] name = "markdown" # https://github.com/executablebooks/mdformat formatter = { command = "mdformat", args = ["-"] } [[language]] name = "json" formatter = { command = "prettier", args = ["--parser", "json"] } [[language]] name = "toml" auto-format = true # https://github.com/bd82/toml-tools/tree/master/packages/prettier-plugin-toml formatter = { command = "prettier", args = ["--parser", "toml"] } [[language]] name = "yaml" indent = { tab-width = 2, unit = " " } formatter = { command = "prettier", args = ["--parser", "yaml"] } [[language]] name = "astro" scope = "source.astro" injection-regex = "astro" file-types = ["astro"] roots = ["package.json", "astro.config.mjs"] language-server = { command = "astro-ls", args = ["--stdio"] } config = { "typescript" = { serverPath = "/Users/matteostara/.nvm/versions/node/v18.16.0/bin/typescript-language-server" }, "environment" = "node" }
For example I want to reject poorly formatted commit messages with https://github.com/compilerla/conventional-pre-commit
Project mention: Which is your favourite or go-to YouTube channel for being up-to-date on Python? | /r/Python | 2023-05-05He made yesqa and pyupgrade (among others), and also works on flake8. His main job is for https://sentry.io/.
Project mention: Template for Cython + Poetry + PoetryDynamicVersioning + GithubActions + CIBuildWheel | /r/Python | 2023-06-08
Project mention: How to setup Black and pre-commit in python for auto text-formatting on commit | dev.to | 2024-03-29All the Code used in this article can be found on this GitHub repo here
Python pre-commit related posts
- How to setup Black and pre-commit in python for auto text-formatting on commit
- Implementing Quality Checks In Your Git Workflow With Hooks and pre-commit
- [Tool Anouncement] github-distributed-owners - A tool for managing GitHub CODEOWNERS using OWNERS files distributed throughout your code base. Especially helpful for monorepos / multi-team repos
- Packaging Python projects in 2023 from scratch
- How to Write Impeccably Clean Code That Will Save Your Sanity
- Setting Up Pre-Commit Hooks in GitHub: Ensuring Code Quality and Consistency
- I’m a hack and a fraud - what are some dead giveaways that someone is self taught?
-
A note from our sponsor - InfluxDB
www.influxdata.com | 19 Apr 2024
Index
What are some of the best open-source pre-commit projects in Python? This list will help you:
Project | Stars | |
---|---|---|
1 | pre-commit | 12,006 |
2 | pre-commit-hooks | 4,852 |
3 | pyupgrade | 3,323 |
4 | nbQA | 959 |
5 | reorder-python-imports | 709 |
6 | nn-template | 612 |
7 | FastAPI-Backend-Template | 551 |
8 | mdformat | 345 |
9 | conventional-pre-commit | 281 |
10 | yesqa | 257 |
11 | python-template | 228 |
12 | autohooks | 183 |
13 | check-jsonschema | 176 |
14 | cookiecutter-fastapi-backend | 102 |
15 | pre-commit-hook-yamlfmt | 55 |
16 | django-urlconfchecks | 54 |
17 | flake8-typing-imports | 48 |
18 | pre-commit-config-shellcheck | 7 |
19 | version-checker | 4 |
20 | pushpin | 2 |
21 | black-pre-commit-example-setup | 0 |