Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vendor fprettify autoformater and add to CI #167

Merged
merged 3 commits into from
Nov 1, 2023
Merged

Conversation

danielhollas
Copy link
Contributor

@danielhollas danielhollas commented Oct 30, 2023

Unfortunately, fprettify autoformatter is not maintained much, and we need some fixes for it to work for ABIN. So we simply copy the source code with the fixes in the repo to make our lives simpler. The code can now be autoformatted simply by running

./autoformat.py

(assuming the configargparse Python module is installed.)

The formatter source code is vendored in fprettify/ (no need to review those files).

We now check the formatting in Github Actions, I've modified CONTRIBUTING.md accordingly.

@codecov
Copy link

codecov bot commented Oct 30, 2023

Codecov Report

Merging #167 (f9f0615) into master (542b515) will not change coverage.
The diff coverage is 62.79%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #167   +/-   ##
=======================================
  Coverage   92.37%   92.37%           
=======================================
  Files          43       43           
  Lines        6084     6084           
  Branches      741      741           
=======================================
  Hits         5620     5620           
  Misses        452      452           
  Partials       12       12           
Flag Coverage Δ
unittests 24.67% <0.00%> (ø)

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

Files Coverage Δ
src/abin.F90 93.12% <100.00%> (ø)
src/cmdline.F90 100.00% <ø> (ø)
src/force_terash.F90 97.02% <100.00%> (ø)
src/surfacehop.F90 95.60% <100.00%> (ø)
src/tera_mpi_api.F90 97.00% <100.00%> (ø)
src/utils.F90 98.18% <100.00%> (ø)
src/landau_zener.F90 90.03% <95.45%> (ø)
src/force_tcpb.F90 29.72% <6.25%> (ø)

@danielhollas danielhollas force-pushed the vendor-fprettify branch 2 times, most recently from 40f4c1c to e604927 Compare October 31, 2023 18:14
Copy link
Contributor

@JanosJiri JanosJiri left a comment

Choose a reason for hiding this comment

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

Seems to do nice formatting of the code.

@danielhollas danielhollas merged commit 51ccb46 into master Nov 1, 2023
18 of 19 checks passed
@danielhollas danielhollas deleted the vendor-fprettify branch November 1, 2023 13:44
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.

2 participants