Skip to content

Add clippy linting and fix existing warnings#287

Merged
bee-san merged 6 commits into
bee-san:masterfrom
niklasmohrin:clippy
Oct 17, 2020
Merged

Add clippy linting and fix existing warnings#287
bee-san merged 6 commits into
bee-san:masterfrom
niklasmohrin:clippy

Conversation

@niklasmohrin
Copy link
Copy Markdown
Contributor

Closes #276

I split the stuff up into separate commits, but I guess they could also be squashed.

  • Fix clippy warnings around match expressions
  • Fix clippy warnings about syntax
  • Fix clippy warnings around return statements that could just be expressions
  • Fix clippy warnings around under-specific method calls
  • Add clippy workflow

I am not sure about the workflow as it uses some "secret token", but this is how it is set up over at tealdeer. On the project page, it says that it is used to add the annotations to the PR diff. If you don't like that, I could replace it with a workflow that just checks the lints.

@niklasmohrin
Copy link
Copy Markdown
Contributor Author

niklasmohrin commented Oct 17, 2020

You can already see the workflow in action (it cannot add the annotations currently, because this is only live on a fork). I think the lints should be required to pass, but I left it optional for now. Let me know what you think!

Copy link
Copy Markdown
Contributor

@bernardoamc bernardoamc left a comment

Choose a reason for hiding this comment

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

Awesome <3

@bee-san
Copy link
Copy Markdown
Owner

bee-san commented Oct 17, 2020

Amazing!!! Thank you so much!! We've been meaning to do this for a while :P @all-contributors please add @niklasmohrin for code and bugs!

@allcontributors
Copy link
Copy Markdown
Contributor

@bee-san

I've put up a pull request to add @niklasmohrin! 🎉

@bee-san bee-san merged commit ed41af2 into bee-san:master Oct 17, 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.

Linting with cargo clippy

3 participants