#51089 Integrate pre-commit
Closed: wontfix 3 years ago by spichugi. Opened 3 years ago by vashirov.

Issue Description

pre-commit is a framework for managing and maintaining multi-language pre-commit hooks.

We can integrate various linters/formatters/checkers into our git workflow so that they will be executed automatically on git commit/push or at any other stage. Of course, they can be skipped, if needed.

I propose a list of tools that we should be running by default:

We also need to add our own checks:

  • To automatically add pytest marks to pytest.ini
  • Check commit message if it contains all the required information. We have a git commit template, but it's not enforced.

WDYT?


I agree, we should have these. My advice would be to gradually add them:

  • clang-format + black initially
  • flake8 next

Then we do once off runs of flynt and removestar.

It may also be worth considering cargo fmt under src as well.

Metadata Update from @firstyear:
- Custom field origin adjusted to None
- Custom field reviewstatus adjusted to None

3 years ago

Metadata Update from @mreynolds:
- Issue priority set to: normal
- Issue set to the milestone: 1.4.4

3 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/4142

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix
- Issue status updated to: Closed (was: Open)

3 years ago

Login to comment on this ticket.

Metadata