`miqbot` CLI
It would be nice for developers to be able to run the same linters that the bot does from their own machine via a miqbot CLI command, or some other form.
Some considerations:
- Making it a gem would allow for an easy install, but I think based on some issues with including it in a bundle, it is preferred to have it as a separate install. We could probably just add a
miqbot.gemspecthat pulls only what we need from thelib/dir to make this happen. - Might want to make some changes to the worker classes so that the same code paths they call into are what is being called in via the CLI. I don't for see this being a lot of work, just want to make sure that we are supplying methods for the classes in
libwith non-activerecord objects and only the service objects as input. This might already be the case, but I would have to check. - The "public configs" notion on https://github.com/ManageIQ/miq_bot/issues/486 would be relevant for this if there is anything that is "config specific" that we would want developers to have when running locally. Not sure there is, but would have to check.
-
prontois already CLI based, and there was an effort a while back to make use of this instead of our custom code (see #406, #412, and #424 for details). This probably wouldn't replace the need for a custommiqbotcommand, but it would greatly simplify the glue needed for that, and we probably could just inherit a lot of things from that project for our implementation.
Yeah I was thinking that maybe we get pronto over the finish line, and then like you said just inherit a lot from that.
I wonder if our "custom" commit checking stuff can also just be more linter entries under pronto or rubocop.
Possibly. I would have to do some research on what we have already attempted with the pronto effort (and pronto in general), but that would be nice.
Really like this idea overall...would be cool to be able to run the guts of the bot locally. I have to wrap my head around it a bit more. I'm wondering if it makes sense to extraact the guts into a separate gem with the bin/cli and the actual pieces of work, then miq_bot the "Rails app" takes care of the database, sidekiq, and calling into the library.
Yeah, I was considering the gem library bit myself. The approach I was considering was just "one gem" to avoid needing a "lib gem" and a "cli gem".
However, I guess if the rails app consumed the miqbot cli gem, that is effectively one gem as well.
¯\(°_o)/¯
:heart: for pronto
This issue has been automatically marked as stale because it has not been updated for at least 3 months.
If you can still reproduce this issue on the current release or on master, please reply with all of the information you have about it in order to keep the issue open.
Thank you for all your contributions! More information about the ManageIQ triage process can be found in the triage process documentation.