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

👷 Lint PRs #2

Merged
merged 1 commit into from
May 22, 2020
Merged

👷 Lint PRs #2

merged 1 commit into from
May 22, 2020

Conversation

fiendish
Copy link
Contributor

No description provided.

@dankolbman
Copy link
Contributor

I think this action will do the same thing: https://github.com/marketplace/actions/black-code-formatter

@fiendish
Copy link
Contributor Author

fiendish commented May 19, 2020

I looked at that also, but it only does black and doesn't flake, and it's not clear to me what value is provided by an action that does so little vs just running the tool.

And even if we used that, we'd still need a workflow file to invoke it.

@@ -0,0 +1,24 @@
name: Python application
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm confused by why this is part of release maker? Is it assuming release maker will only run on Python repos?

Copy link
Contributor Author

@fiendish fiendish May 21, 2020

Choose a reason for hiding this comment

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

This isn't part of release maker. It's linting this repository, which houses python code.
This confusion is actually why I initially had the gh_release.yml file in another folder too. I welcome your thoughts on how to organize things.

[edit: for now I've moved the gh_release.yml back to the central location and symlinked it into this repo's .github/workflows dir (and updated the readme). Hopefully it still works on this repo as a symlink]

run: |
python -m pip install --upgrade pip
pip install flake8 black
- name: Lint
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should this step run on *.py? ..I thought I saw that before but it disappeared

Copy link
Contributor Author

@fiendish fiendish May 21, 2020

Choose a reason for hiding this comment

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

Flake8 automatically does its own search for .py files from . The only reason to avoid using that is to bypass thousands of virtualenv files, but there's no virtualenv here.

mkdir -p foo/bar
echo "import a" > foo/foo.py
echo "import a" > foo/bar/bar.py
flake8 .
./foo/foo.py:1:1: F401 'a' imported but unused
./foo/bar/bar.py:1:1: F401 'a' imported but unused

@znatty22 znatty22 self-requested a review May 21, 2020 15:45
Copy link
Collaborator

@znatty22 znatty22 left a comment

Choose a reason for hiding this comment

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

👍

@fiendish fiendish merged commit a5bd6cc into master May 22, 2020
@fiendish fiendish deleted the lint-action branch May 22, 2020 14:54
fiendish added a commit that referenced this pull request Jun 3, 2020
## Release 1.0.0

### Summary

- Emojis: 👷 x1, 🎉 x1
- Categories: Ops x1, Additions x1

### New features and changes

- [#2](#2) - 👷 Lint PRs - [a5bd6cc](a5bd6cc) by [fiendish](https://github.com/fiendish)
- [#1](#1) - 🎉 New release maker - [1c49d0a](1c49d0a) by [fiendish](https://github.com/fiendish)
@fiendish fiendish mentioned this pull request Jun 3, 2020
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.

3 participants