Skip to content

Add pre-commit hooks#293

Merged
snk4tr merged 4 commits intomasterfrom
feature/pre-commit
Feb 11, 2022
Merged

Add pre-commit hooks#293
snk4tr merged 4 commits intomasterfrom
feature/pre-commit

Conversation

@jzakirov
Copy link
Collaborator

@jzakirov jzakirov commented Feb 6, 2022

Closes #271

Proposed Changes

  • Add pre-commit config and setup guide
  • Format all files according to it
  • Fix spelling issues

@snk4tr you wanted to do this yourself, but I'm just tired of formatting files by hand 😄
This should eliminate "Fix flake8" and "Fix mypy" commits entirely.

Ready for review. It seems like a lot of files have changed, but it's mostly whitespace difference.

@jzakirov jzakirov requested a review from snk4tr February 6, 2022 21:37
@sonarqubecloud
Copy link

sonarqubecloud bot commented Feb 6, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov
Copy link

codecov bot commented Feb 6, 2022

Codecov Report

Merging #293 (b767ad9) into master (6e06c80) will decrease coverage by 2.27%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #293      +/-   ##
==========================================
- Coverage   93.27%   91.00%   -2.28%     
==========================================
  Files          33       33              
  Lines        2289     2289              
==========================================
- Hits         2135     2083      -52     
- Misses        154      206      +52     
Flag Coverage Δ
unittests 91.00% <100.00%> (-2.28%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
piq/base.py 88.46% <ø> (ø)
piq/dss.py 98.96% <ø> (ø)
piq/fsim.py 100.00% <ø> (ø)
piq/functional/base.py 92.10% <ø> (ø)
piq/functional/colour_conversion.py 100.00% <ø> (ø)
piq/functional/resize.py 67.14% <ø> (ø)
piq/gmsd.py 100.00% <ø> (ø)
piq/gs.py 32.96% <ø> (-57.15%) ⬇️
piq/haarpsi.py 100.00% <ø> (ø)
piq/mdsi.py 100.00% <ø> (ø)
... and 13 more

Copy link
Collaborator

@denproc denproc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@snk4tr snk4tr merged commit 6a7bda3 into master Feb 11, 2022
@snk4tr snk4tr deleted the feature/pre-commit branch February 11, 2022 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add precommit-hooks to automatically check code formatting.

3 participants