rubocop-daemon icon indicating copy to clipboard operation
rubocop-daemon copied to clipboard

Restart server automatically on config change

Open tdeo opened this issue 3 years ago • 0 comments

Hello,

I noticed some inconsistencies when using rubocop-daemon and changing rubocop's config file, the changes aren't reloaded until I restart the server.

I looked a bit around Rubocop, and there doesn't seem to be an API to reload the whole config. I'm quite willing to look into making a PR for that - I believe it could be implement in ClientCommand::Base#ensure_server! by appending a first line like ClientCommand::Stop.new([]).run if Daemon.configuration_obsolete? and having a configuration_checksum of some sort handled by Cache.

Do you think that is the right direction ? Would you have any other suggestions for implementing that behavior?

tdeo avatar Oct 27 '21 07:10 tdeo