diff --git a/ADDONS.md b/ADDONS.md index c10344533..7e4d9cef8 100644 --- a/ADDONS.md +++ b/ADDONS.md @@ -304,7 +304,7 @@ end ### Registering for file update events By default, the Ruby LSP listens for changes to files ending in `.rb` to continuously update its index when Ruby source -code is modified. If your your addon uses a tool that is configured through a file (like RuboCop and its `.rubocop.yml`) +code is modified. If your addon uses a tool that is configured through a file (like RuboCop and its `.rubocop.yml`) you can register for changes to these files and react when the configuration changes. **Note**: you will receive events from `ruby-lsp` and other addons as well, in addition to your own registered ones. @@ -321,8 +321,8 @@ module RubyLsp def deactivate; end def register_additional_file_watchers(global_state, message_queue) - # Clients are not required to implement this capability - return unless global_state.supports_watching_files + # Clients are not required to implement this capability + return unless global_state.supports_watching_files message_queue << Request.new( id: "ruby-lsp-my-gem-file-watcher", @@ -352,10 +352,6 @@ module RubyLsp # Do something to reload the config here end end - - def name - "Ruby LSP My Gem" - end end end end