-
Notifications
You must be signed in to change notification settings - Fork 5
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
Added black and flake8 as GitHub actions blockers #25
base: master
Are you sure you want to change the base?
Conversation
.github/workflows/python_lint.yml
Outdated
- name: If needed, commit black changes to a new pull request | ||
if: failure() | ||
run: | | ||
black . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Could you add those as blockers. Like check if black
formatting is correct?
black -v .
was for this I think.
And the same for pyflake8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok so only formatting check should be done?
I have added auto formatting action too
which formats itself and pushes a formatted code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep - put only formatting check - the developer should make sure the code is clean before pushing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added 💯
@gmuraru
As you can see here https://github.com/gmuraru/MiceNDemons/pull/25/checks?check_run_id=1219688894
Already there are some files having errors!
And the action will annotate automatically, just add the GITHUBTOKEN
as your repo secret and its done 👍🏻
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep - could you put the limit to 80 characters, please. And after this, the commit should respect a specific format. Even if black/flake8 fails I can merge this and I can put up a fix later for it.
uses: actions/checkout@master | ||
- name: Install flake8 | ||
run: pip install flake8 | ||
- uses: grantmcconnaughey/lintly-flake8-github-action@v1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Could this be removed?
- name: Install flake8 | ||
run: pip install flake8 | ||
- uses: grantmcconnaughey/lintly-flake8-github-action@v1.0 | ||
with: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Could we remove everything from this with?
Black and Flake8 - Github Action
Added black and flake8 as GitHub actions blockers 💯
Fixes #23
You need to add secrets to the repo -