Gitlint

Latest version: v0.19.1

Safety actively analyzes 626941 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 5

0.15.1

Contributors:
Special thanks to all contributors for this release, in particular [PW999](https://github.com/PW999), [gsemet](https://github.com/gsemet) and [Lorac](https://github.com/Lorac).

Bugfixes
- Git commit message body with only new lines is not longer considered empty by `body-is-missing` ([176](https://github.com/jorisroovers/gitlint/issues/176))
- Added compatibility with `git commit -s` for `contrib-requires-signed-off-by` rule ([178](https://github.com/jorisroovers/gitlint/pull/178))
- Minor tweak to gitlint commit-hook output ([173](https://github.com/jorisroovers/gitlint/pull/173))
- All dependencies have been upgraded to the latest available versions (`Click==7.1.2`, `arrow==1.0.3`, `sh==1.14.1`).
- Minor doc fixes

0.15.0

Contributors:
Special thanks to [BrunIF](https://github.com/BrunIF), [lukech](https://github.com/lukech), [Cielquan](https://github.com/Cielquan), [harens](https://github.com/harens) and [sigmavirus24](https://github.com/sigmavirus24).

General

- **This release drops support for Python 2.7 and Python 3.5 ([both are EOL](https://endoflife.date/python)). Other than a few minor fixes, there are no functional differences from the 0.14.0 release.**
- **Mac users**: Gitlint can now be installed using both homebrew (upgraded to latest) and macports. Special thanks to [harens](https://github.com/harens) for maintaining these packages (best-effort).

Bugfixes
- Gitlint now properly handles exceptions when using its built-in commit-msg hook ([166](https://github.com/jorisroovers/gitlint/issues/166)).

Development
- All dependencies have been upgraded to the latest available versions (`Click==7.1.2`, `arrow==0.17.0`, `sh==1.14.1`).
- Much under-the-hood refactoring as a result of dropping Python 2.7

0.14.0

Contributors:
Special thanks to all contributors for this release, in particular [mrshu](https://github.com/mrshu), [glasserc](https://github.com/glasserc), [strk](https://github.com/strk), [chgl](https://github.com/chgl), [melg8](https://github.com/melg8) and [sigmavirus24](https://github.com/sigmavirus24).

General
- **IMPORTANT: Gitlint 0.14.x will be the last gitlint release to support Python 2.7 and Python 3.5, as [both are EOL](https://endoflife.date/python) which makes it difficult to keep supporting them.**
- Python 3.9 support
- [Named Rules](https://jorisroovers.github.io/gitlint/rules/named_rules/) allow users to have multiple instances of the same rule active at the same time. This is useful when you want to enforce the same rule multiple times but with different options ([#113](https://github.com/jorisroovers/gitlint/issues/113), [#66](https://github.com/jorisroovers/gitlint/issues/66))
- [User-defined Configuration Rules](https://jorisroovers.github.io/gitlint/rules/user_defined_rules/configuration_rules/) allow users to dynamically change gitlint's configuration and/or the commit *before* any other rules are applied.
- The `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.
- Most general options can now be set through environment variables (e.g. set the `general.ignore` option via `GITLINT_IGNORE=T1,T2`). The list of available environment variables can be found in the [configuration documentation](https://jorisroovers.github.io/gitlint/configuration).
- Users can now use `self.log.debug("my message")` for debugging purposes in their user-defined rules. Debug messages will show up when running `gitlint --debug`.
- **Breaking**: User-defined rule id's can no longer start with 'I', as those are reserved for [built-in gitlint ignore rules](https://jorisroovers.github.io/gitlint/rules/builtin_rules/#i1-ignore-by-title).
- New `RegexOption` rule [option type for use in user-defined rules](https://jorisroovers.github.io/gitlint/rules/user_defined_rules/options/). 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.

Rules
- **New Rule**: [title-min-length](https://jorisroovers.github.io/gitlint/rules/builtin_rules/#t8-title-min-length) enforces a minimum length on titles (default: 5 chars) ([138](https://github.com/jorisroovers/gitlint/issues/138))
- **New Rule**: [body-match-regex](https://jorisroovers.github.io/gitlint/rules/builtin_rules/#b8-body-match-regex) allows users to enforce that the commit-msg body matches a given regex ([130](https://github.com/jorisroovers/gitlint/issues/130))
- **New Rule**: [ignore-body-lines](https://jorisroovers.github.io/gitlint/rules/builtin_rules/#i3-ignore-body-lines) allows users to
[ignore parts of a commit](https://jorisroovers.github.io/gitlint/ignoring_commits/) by matching a regex against
the lines in a commit message body ([126](https://github.com/jorisroovers/gitlint/issues/126))

Contrib Rules
- Added 'ci' and 'build' to conventional commit types ([135](https://github.com/jorisroovers/gitlint/issues/135))

Bugfixes
- Improved UTF-8 fallback on Windows (ongoing - [96](https://github.com/jorisroovers/gitlint/issues/96))
- Windows users can now use the 'edit' function of the `commit-msg` hook ([94](https://github.com/jorisroovers/gitlint/issues/94))
- Doc update: Users should use `--ulimit nofile=1024` when invoking gitlint using Docker ([129](https://github.com/jorisroovers/gitlint/issues/129))
- The `commit-msg` hook was broken in Ubuntu's gitlint package due to a python/python3 mismatch ([127](https://github.com/jorisroovers/gitlint/issues/127))
- Better error message when no git username is set ([149](https://github.com/jorisroovers/gitlint/issues/149))
- Options can now actually be set to `None` (from code) to make them optional.
- Ignore rules no longer have `"None"` as default regex, but an empty regex - effectively disabling them by default (as intended).

Development
- Minor performance improvements (removed some unnecessary regex matching),
- Test improvements,
- Improved debug logging,
- CI runs on pull requests
- PR request template

0.13.1

Bugfixes
- Patch to enable `--staged` flag for pre-commit.
- Minor doc updates ([109](https://github.com/jorisroovers/gitlint/issues/109))

0.13.0

General
- Python 3.8 support
- Python 3.4 no longer supported. Python 3.4 has [reached EOL](https://www.python.org/dev/peps/pep-0429/#id4) and an increasing
of gitlint's dependencies have dropped support which makes it hard to maintain.
- Improved Windows support: better unicode handling. [Issues remain](https://github.com/jorisroovers/gitlint/issues?q=is%3Aissue+is%3Aopen+label%3Awindows) but the basic functionality works.
- **Behavior Change**: Revert Commits are now recognized and ignored by default ([99](https://github.com/jorisroovers/gitlint/issues/99))

Features
- `--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](https://jorisroovers.github.io/gitlint/commit_hooks/) or [precommit](https://jorisroovers.github.io/gitlint/commit_hooks/#pre-commit) ([105](https://github.com/jorisroovers/gitlint/issues/105))
- New branch properties on `GitCommit` and `GitContext`, useful when writing your own user-defined rules: `commit.branches` and `commit.context.current_branch` ([108](https://github.com/jorisroovers/gitlint/issues/108))

Bugfixes
- Gitlint no longer crashes when acting on empty repositories (this only occurred in specific circumstances).
- Changed files are now better detected in repos that only have a root commit
- Improved performance and memory (gitlint now caches git properties)
- Improved `--debug` output
- Improved documentation

Development
- Dependencies updated
- Unit and integration test improvements
- Migrated from TravisCI to Github Actions.

0.12.0

Contributors:
Special thanks to all contributors for this release, in particular [rogalksi](https://github.com/rogalski) and [byrney](https://github.com/byrney).

General
- Python 3.3 no longer supported. Python 3.4 is likely to follow in a future release as it has [reached EOL](https://www.python.org/dev/peps/pep-0429/#id4) as well.
- PyPy 3.5 support


Features
- [Contrib Rules](https://jorisroovers.github.io/gitlint/contrib_rules): community-contributed rules that are disabled
by default, but can be enabled through configuration. Contrib rules are meant to augment default gitlint behavior by
providing users with rules for common use-cases without forcing these rules on all gitlint users.
- **New Contrib Rule**: `contrib-title-conventional-commits` enforces the [Conventional Commits](https://www.conventionalcommits.org) spec. Details in our [documentation](https://jorisroovers.github.io/gitlint/contrib_rules/#ct1-contrib-title-conventional-commits).
- **New Contrib Rule**: `cc1-contrib-requires-signed-off-by` ensures that all commit messages contain a `Sign-Off-By` line. Details in our [documentation](https://jorisroovers.github.io/gitlint/rules/contrib_rules/#cc1-contrib-body-requires-signed-off-by).
- If you're interested in adding new Contrib rules to gitlint, please start by reading the
[Contributing](https://jorisroovers.github.io/gitlint/contributing/) page. Thanks for considering!
- *Experimental (!)* Windows support: Basic functionality is working, but there are still caveats. For more details, please refer to [20](https://github.com/jorisroovers/gitlint/issues/20) and the [open issues related to Windows](https://github.com/jorisroovers/gitlint/issues?q=is%3Aissue+is%3Aopen+label%3Awindows).
- Support for `--ignore-stdin` command-line flag to ignore any text send via stdin. ([56](https://github.com/jorisroovers/gitlint/issues/56), [#89](https://github.com/jorisroovers/gitlint/issues/89))

Bugfixes
- [68: Can't use install-hooks in with git worktree](https://github.com/jorisroovers/gitlint/issues/68)
- [59: gitlint failed with configured commentchar](https://github.com/jorisroovers/gitlint/issues/59)

Development
- Dependencies updated
- Experimental Dockerfile
- Github issue template.

Page 2 of 5

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.