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

chore: add check_code_format workflow #19

Merged
merged 22 commits into from
Jun 2, 2023

Conversation

vil02
Copy link
Member

@vil02 vil02 commented May 30, 2023

This PR adds a workflow running the command nim prettyfy on the entire project.

The added workflow is executed on every push to master and pull reques

It turned out, that there are already two files, which are not correctly formatted: c6acd82.

The shell script could be removed thanks to #21.

@dlesnoff
Copy link
Collaborator

I am on a rush, I will test it during the week-end.

I made a lot of spaces on empty lines :(

Very nice first contribution. I guess this fixes issue #16 .

@Panquesito7 Panquesito7 added the enhancement New feature or request label May 31, 2023
@Panquesito7 Panquesito7 linked an issue May 31, 2023 that may be closed by this pull request
.github/workflows/run_nimpretty.yml Outdated Show resolved Hide resolved
.github/workflows/run_nimpretty.yml Outdated Show resolved Hide resolved
@vil02
Copy link
Member Author

vil02 commented May 31, 2023

Very nice first contribution. I guess this fixes issue #16 .

Nimpretty, as far as I can tell, is a code formatter - it does not perform any static analysis.

@vil02
Copy link
Member Author

vil02 commented May 31, 2023

@Panquesito7 Now the workflow fails if there are some *.nim files needing reformatting.

It works on my side:

I hope you were not floated by e-mails with every commit - I have forgotten to change it to a draft.

@vil02 vil02 requested a review from Panquesito7 May 31, 2023 17:21
Panquesito7
Panquesito7 previously approved these changes May 31, 2023
Copy link
Member

@Panquesito7 Panquesito7 left a comment

Choose a reason for hiding this comment

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

Looks great! Thanks. 🚀

@vil02 vil02 changed the title chore add run_nimpretty workflow chore: add run_nimpretty workflow Jun 1, 2023
.github/workflows/run_nimpretty.yml Outdated Show resolved Hide resolved
.github/workflows/run_nimpretty.yml Outdated Show resolved Hide resolved
run_nimpretty.sh Outdated Show resolved Hide resolved
@ZoomRmc
Copy link
Contributor

ZoomRmc commented Jun 1, 2023

I propose replacing the bash script with a task from #21.

@vil02 vil02 changed the title chore: add run_nimpretty workflow chore: add check_code_format workflow Jun 2, 2023
@dlesnoff dlesnoff merged commit a2fc1bd into TheAlgorithms:main Jun 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a GitHub workflow that checks the code (Nim linter)
4 participants