NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
PyPI · #5041 most downloaded on PyPI
Git commit message linter written in python, checks your commit messages for style.
Last release 3 years ago
no release in 18 months
Release timing varies
gaps range from 8 days to 6 weeks
Nearly every release is documented
notes for 27 of 27 stable releases
Nothing withdrawn
no release was ever pulled
11 years old
88 releases · first in 2015
Nothing published for this version
Nothing published for this version
Nothing published for this version
Contributors: Special thanks to all contributors for this release - details inline!
One column per quarter.
Contributors: Special thanks to all contributors for this release - details inline!
re.search instead of re.match semantics for all rules. Your rule regexes might need updating as a result, gitlint will print a warning if so. More details are in the docs. (#254)sh can be re-enabled by setting the env var GITLINT_USE_SH_LIB=1. This fallback will be removed entirely in a future gitlint release. (#351)--commits now also accepts a comma-separated list of commit hashes, making it possible to lint a list of non-contiguous commits without invoking gitlint multiple times (#283)GITLINT_CONFIG env variable (#189) - thanks Notgnoshigitlint-ci pre-commit hook, making it easier to run gitlint through pre-commit in CI (#191) - thanks guillaumelambertfixup=amend commits (see related git documentation), available as commit.is_fixup_amend_commit=Truecommit.changed_files_stats (#314)master branch in favor of mainContributors: Special thanks to all contributors for this release, in particular andersk and sigmavirus24.
Contributors: Special thanks to all contributors for this release, in particular andersk and sigmavirus24.
gitlint and gitlint-core. This allows users to install gitlint without pinned dependencies (which is the default) (#162)contrib-title-conventional-commits (CT1) now supports the BREAKING CHANGE symbol "!"
Contributors: Special thanks to all contributors for this release, in particular sigmavirus24, l0b0 and rafaelbubach.
--commit <SHA> flag to more easily lint a single commit message (#141)--fail-without-commits flag will force gitlint to fail (exit code 253) when the target commit range is empty (typically when using --commits) (#193)Contributors: Special thanks to all contributors for this release, in particular sigmavirus24, l0b0 and rafaelbubach.
--commit <ref> flag to more easily lint a single commit message (#141)--fail-without-commits flag will force gitlint to fail (exit code 253) when the target commit range is empty (typically when using --commits) (#193)Contributors: Special thanks to all contributors for this release, in particular PW999, gsemet and Lorac.
Contributors: Special thanks to all contributors for this release, in particular PW999, gsemet and Lorac.
Bugfixes:
body-is-missing (#176)git commit -s for contrib-requires-signed-off-by rule (#178)Click==7.1.2, arrow==1.0.3, sh==1.14.1).Contributors: Special thanks to BrunIF, lukech, Cielquan, harens and sigmavirus24.
Contributors: Special thanks to BrunIF, lukech, Cielquan, harens and sigmavirus24.
This release drops support for Python 2.7 and Python 3.5 (both are EOL). Other than a few minor fixes, there are no functional differences from the 0.14.0 release.
Other call-outs:
Click==7.1.2, arrow==0.17.0, sh==1.14.1).Contributors: Special thanks to all contributors for this release, in particular @mrshu, @glasserc, @strk, @chgl, @melg8 and @sigmavirus24.
Contributors: Special thanks to all contributors for this release, in particular @mrshu, @glasserc, @strk, @chgl, @melg8 and @sigmavirus24.
commit-msg hook has been re-written in Python (it contained a lot of Bash before), fixing a number of platform specific issues. Existing users will need to reinstall their hooks (gitlint uninstall-hook; gitlint install-hook) to make use of this.general.ignore option via GITLINT_IGNORE=T1,T2). The list of available environment variables can be found in the configuration documentation.self.log.debug("my message") for debugging purposes in their user-defined rules. Debug messages will show up when running gitlint --debug.RegexOption rule option type for use in user-defined rules. By using the RegexOption, regular expressions are pre-validated at gitlint startup and compiled only once which is much more efficient when linting multiple commits.commit-msg hook (#94)--ulimit nofile=1024 when invoking gitlint using Docker (#129)commit-msg hook was broken in Ubuntu's gitlint package due to a python/python3 mismatch (#127)None (from code) to make them optional."None" as default regex, but an empty regex - effectively disabling them by default (as intended).Patch to enable --staged flag for pre-commit.
--staged flag for pre-commit.Behavior Change: Revert Commits are now recognized and ignored by default
--staged flag: gitlint can now detect meta-data (such as author details, changed files, etc) of staged/pre-commits. Useful when you use gitlint's commit-msg hook or precommit (#105)GitCommit and GitContext, useful when writing your own user-defined rules: commit.branches and commit.context.current_branch (#108)--debug output--staged flag: gitlint can now detect meta-data (such as author details, changed files, etc) of staged/pre-commits. Useful when you use gitlint's commit-msg hook or precommit (#105)GitCommit and GitContext, useful when writing your own user-defined rules: commit.branches and commit.context.current_branch (#108)--debug outputContributors: Special thanks to all contributors for this release, in particular @rogalksi and @byrney.
Contributors: Special thanks to all contributors for this release, in particular @rogalksi and @byrney.
contrib-title-conventional-commits enforces the Conventional Commits spec. Details in our documentation.cc1-contrib-requires-signed-off-by ensures that all commit messages contain a Sign-Off-By line. Details in our documentation.--ignore-stdin command-line flag to ignore any text send via stdin. (#56, #89)Contributors: Special thanks to all contributors for this release, in particular @rogalksi and @byrney.
contrib-title-conventional-commits enforces the Conventional Commits spec. Details in our documentation.cc1-contrib-requires-signed-off-by ensures that all commit messages contain a Sign-Off-By line. Details in our documentation.--ignore-stdin command-line flag to ignore any text send via stdin. (#56, #89)Various dependency updates and under the hood fixes (see #76 for details)
Special thanks to @pbregener for his contributions related to python 3.7 support and test fixes.
Special thanks to @pbregener for his contributions related to python 3.7 support and test fixes.
The 0.10.0 release adds the ability to ignore commits based on their contents, support for pre-commit, and important fix for running gitlint in CI env
The 0.10.0 release adds the ability to ignore commits based on their contents, support for pre-commit, and important fix for running gitlint in CI environments (such as Jenkins, Gitlab, etc).
Special thanks to @asottile, @bdrung, @pbregener, @torwald-sergesson, @RykHawthorn, @SteffenKockel and @tommyip for their contributions.
Since it's becoming increasingly hard to support Python 2.6 and 3.3, we'd like to encourage our users to upgrade their python version to 2.7 or 3.3+. Future versions of gitlint are likely to drop support for Python 2.6 and 3.3.
Full Changelog:
ignore-by-title allows users to ignore certain commits by matching a regex against a commit message title. (#54, #57).ignore-by-body allows users to ignore certain commits by matching a regex against a line in a commit message body.--msg-filename commandline flag that allows you to specify the commit message to lint via a file (#39).The 0.10.0 release adds the ability to ignore commits based on their contents, support for pre-commit, and important fix for running gitlint in CI environments (such as Jenkins, Gitlab, etc).
Special thanks to asottile, bdrung, pbregener, torwald-sergesson, RykHawthorn, SteffenKockel and tommyip for their contributions.
--msg-filename commandline flag that allows you to specify the commit message to lint via
a file (#39).ignore-by-title allows users to
ignore certain commits by matching a regex against
a commit message title. (#54, #57).ignore-by-body allows users to
ignore certain commits by matching a regex against
a line in a commit message body.Breaking change: The `--commits commandline flag now strictly follows the refspec format as interpreted by the [git rev-list ](https://git-scm.com/doc…
The 0.9.0 release adds a new default author-valid-email rule, important bugfixes and special case handling.
Special thanks to joshholl, ron8mcr, omarkohl, domo141, nud and AlexMooney for their contributions.
author-valid-email enforces a valid author email address. Details can be found in the
Rules section of the documentation.--commits commandline flag now strictly follows the refspec format as interpreted by the git rev-list <refspec> command. This means that linting a single commit using gitlint --commits <SHA> won't work anymore. Instead, for single commits, users now need to specificy gitlint --commits <SHA>^...<SHA>. On the upside, this change also means that gitlint will now understand all refspec formatters, including gitlint --commits HEAD to lint all commits in the repository. This fixes #23.git commit --cleanup=scissors (#34)The 0.9.0 release adds a new default author-valid-email rule, important bugfixes and special case handling.
Special thanks to joshholl, ron8mcr,
omarkohl, domo141, nud
and AlexMooney for their contributions.
--commits commandline flag now strictly follows the refspec format as interpreted
by the git rev-list <refspec> command. This means
that linting a single commit using gitlint --commits <ref> won't work anymore. Instead, for single commits,
users now need to specificy gitlint --commits <ref>^...<ref>. On the upside, this change also means
that gitlint will now understand all refspec formatters, including gitlint --commits HEAD to lint all commits
in the repository. This fixes #23.git commit --cleanup=scissors
(#34)author-valid-email enforces a valid author email address. Details can be found in the
Rules section of the documentation.The 0.8.2 release brings minor improvements, bugfixes and some under-the-hood changes. Special thanks to tommyip for his contributions.
The 0.8.2 release brings minor improvements, bugfixes and some under-the-hood changes. Special thanks to tommyip for his contributions.
--extra-path now also accepts a file path (in the past only directory paths were accepted).
Thanks to tommyip for implementing this!--debug flag. This is initial work and will continue to be improved upon in later releases.--commitsThe 0.8.2 release brings minor improvements, bugfixes and some under-the-hood changes. Special thanks to tommyip for his contributions.
--extra-path now also accepts a file path (in the past only directory paths where accepted).
Thanks to tommyip for implementing this!--debug flag. This is initial work and will continue to
be improved upon in later releases.--commitsThe 0.8.1 release brings minor tweaks and some experimental features. Special thanks to tommyip for his contributions.
The 0.8.1 release brings minor tweaks and some experimental features. Special thanks to tommyip for his contributions.
The 0.8.0 release is a significant release that has been in the works for a long time. Special thanks to Claymore, gernd and ZhangYaxu for submitting
The 0.8.0 release is a significant release that has been in the works for a long time. Special thanks to Claymore, gernd and ZhangYaxu for submitting bug reports and pull requests.
--debuggeneral.target option can now also be set via -c flags or a .gitlint filerun_tests.sh improvements for developer convenienceBehavior change: gitlint no longer prints the file path by default when using a .gitlint file. The path will still be printed when using the new --deb
Bugfixes:
.gitlint file. The path will still be printed when using the new --debug flag. Special thanks to Slipcon for submitting this.title-match-regex rule. Special thanks to
Slipcon for submitting this.This release contains mostly bugfix and internal code improvements. Special thanks to William Turell and Joe Grund for bug reports and pull requests.
This release contains mostly bugfix and internal code improvements. Special thanks to William Turell and Joe Grund for bug reports and pull requests.
ignore-merge-commit=false.Fix: install-hook and generate-config commands not working when gitlint is installed from pypi.
install-hook and generate-config commands not working when gitlint is installed from pypi.Breaking change: exit code behavior has changed. More details in the Exit codes section of the documentation.
generate-config command generates a sample gitlint config file--target flag allows users to lint different directories than the current working directory--install-hook and --uninstall-hook have been renamed to install-hook and uninstall-hook respectively to better express that they are commands instead of options.--config option no longer accepts directories as valueNew Rule: title-match-regex. Details can be found in the Rules section of the documentation.
title-match-regex. Details can be found in the
Rules section of the documentation.gitlint --uninstall-hookgitlint-ignore: T1, body-hard-tab to your git commit message.
Use gitlint-ignore: all to disable gitlint all together for a specific commit.body-is-missing will now automatically be disabled for merge commits (use the ignore-merge-commit: false option to disable this behavior)Internal fix: added missing comma to setup.py which prevented pypi upload
title-must-not-contain-word now has a words option that can be used to specify which words should not occur in the title
title-must-not-contain-word now has a words option that can be used to specify which words should not occur in the titletitle-must-not-contain-word now has a words option that can be used to specify which words should not
occur in the titleRules can now have their behavior configured through options. For example, the title-max-length rule now has a line-length option.
title-max-length rule now has a line-length option.title-max-length rule now has a line-length option.Bugfix: added missing sh dependency
sh dependencyInitial set of rules: title-max-length, title-trailing-whitespace, title-trailing-punctuation , title-hard-tab, title-must-not-contain-word, body-max-
gitlint fileYour coding agent can read these notes before it upgrades. Set up the MCP server →