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

Cleanup CLI #255

Merged
merged 4 commits into from
Nov 9, 2022
Merged

Cleanup CLI #255

merged 4 commits into from
Nov 9, 2022

Conversation

gmcgibbon
Copy link
Member

@gmcgibbon gmcgibbon commented Nov 3, 2022

What are you trying to accomplish?

Clean up the CLI class.

What approach did you choose and why?

Clean up the CLI to declutter the command parsing where clause and clean up / deprecate old commands that aren't documented.

What should reviewers focus on?

This removes the generate_configs subcommand and deprecates the detect-stale-violations subcommand.

Type of Change

  • Bugfix
  • New feature
  • Non-breaking change (a change that doesn't alter functionality - i.e., code refactor, configs, etc.)

Additional Release Notes

This might be a breaking change if anyone is using the undocumented commands. Since we don't mention them anywhere, I think they are safe to delete.

Checklist

  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • It is safe to rollback this change.

@gmcgibbon gmcgibbon requested a review from a team as a code owner November 3, 2022 23:01
Copy link
Contributor

@alexevanczuk alexevanczuk left a comment

Choose a reason for hiding this comment

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

Thank you!

@@ -32,17 +32,6 @@ def initialize(
@relative_file_set = relative_file_set
end

sig { returns(Result) }
def detect_stale_violations
Copy link
Member

Choose a reason for hiding this comment

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

Let's deprecate this command. It was added by our team long time ago, we don't use it, but nothing prevents people from using it. At least we should deprecate in the stable branch before our next release and remove on main.

Copy link
Member Author

Choose a reason for hiding this comment

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

This was my hesitation with merging. I made sure we weren't using it, but I don't know about others. We could just kill them in the next major release, but deprecating this one sounds good to me.

@gmcgibbon gmcgibbon force-pushed the cleanup_cli branch 2 times, most recently from aeebd53 to ed2e247 Compare November 8, 2022 18:07
init does the same thing and this command is not documented.
Makes command parsing where clause easier to read.
This command's output is in check and isn't documented.
@gmcgibbon gmcgibbon merged commit 16db3d0 into main Nov 9, 2022
@gmcgibbon gmcgibbon deleted the cleanup_cli branch November 9, 2022 22:31
gmcgibbon added a commit that referenced this pull request Nov 15, 2022
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