From 1fee1f8656a96357d41089e26fc3bcf148d3a53d Mon Sep 17 00:00:00 2001 From: Stan Lo Date: Mon, 18 Dec 2023 22:22:50 +0000 Subject: [PATCH] Fix listener requires --- lib/ruby_lsp/executor.rb | 2 +- lib/ruby_lsp/requests/code_lens.rb | 3 +-- lib/ruby_lsp/requests/completion.rb | 2 +- lib/ruby_lsp/requests/definition.rb | 2 +- lib/ruby_lsp/requests/document_highlight.rb | 2 +- lib/ruby_lsp/requests/document_link.rb | 2 +- lib/ruby_lsp/requests/document_symbol.rb | 2 +- lib/ruby_lsp/requests/folding_ranges.rb | 2 +- lib/ruby_lsp/requests/hover.rb | 2 +- lib/ruby_lsp/requests/inlay_hints.rb | 2 +- lib/ruby_lsp/requests/semantic_highlighting.rb | 2 +- lib/ruby_lsp/requests/signature_help.rb | 2 +- 12 files changed, 12 insertions(+), 13 deletions(-) diff --git a/lib/ruby_lsp/executor.rb b/lib/ruby_lsp/executor.rb index 04277d4d5..7ee19faa9 100644 --- a/lib/ruby_lsp/executor.rb +++ b/lib/ruby_lsp/executor.rb @@ -551,7 +551,7 @@ def initialize_request(options) end semantic_tokens_provider = if enabled_features["semanticHighlighting"] - require_relative "listeners/semantic_highlighting" + require "ruby_lsp/listeners/semantic_highlighting" Interface::SemanticTokensRegistrationOptions.new( document_selector: { scheme: "file", language: "ruby" }, legend: Interface::SemanticTokensLegend.new( diff --git a/lib/ruby_lsp/requests/code_lens.rb b/lib/ruby_lsp/requests/code_lens.rb index c8ce444f3..c4f79c233 100644 --- a/lib/ruby_lsp/requests/code_lens.rb +++ b/lib/ruby_lsp/requests/code_lens.rb @@ -1,8 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "support/common" -require_relative "../listeners/code_lens" +require "ruby_lsp/listeners/code_lens" require "shellwords" diff --git a/lib/ruby_lsp/requests/completion.rb b/lib/ruby_lsp/requests/completion.rb index d7b27cbcf..690fefa10 100644 --- a/lib/ruby_lsp/requests/completion.rb +++ b/lib/ruby_lsp/requests/completion.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/completion" +require "ruby_lsp/listeners/completion" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/definition.rb b/lib/ruby_lsp/requests/definition.rb index 8d240cc67..1d878712e 100644 --- a/lib/ruby_lsp/requests/definition.rb +++ b/lib/ruby_lsp/requests/definition.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/definition" +require "ruby_lsp/listeners/definition" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/document_highlight.rb b/lib/ruby_lsp/requests/document_highlight.rb index 9ee2c86b8..7f2f4adbd 100644 --- a/lib/ruby_lsp/requests/document_highlight.rb +++ b/lib/ruby_lsp/requests/document_highlight.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/document_highlight" +require "ruby_lsp/listeners/document_highlight" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/document_link.rb b/lib/ruby_lsp/requests/document_link.rb index b574388ce..a4b173990 100644 --- a/lib/ruby_lsp/requests/document_link.rb +++ b/lib/ruby_lsp/requests/document_link.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/document_link" +require "ruby_lsp/listeners/document_link" require "ruby_lsp/requests/support/source_uri" module RubyLsp diff --git a/lib/ruby_lsp/requests/document_symbol.rb b/lib/ruby_lsp/requests/document_symbol.rb index 29f2f07c6..88303d90e 100644 --- a/lib/ruby_lsp/requests/document_symbol.rb +++ b/lib/ruby_lsp/requests/document_symbol.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/document_symbol" +require "ruby_lsp/listeners/document_symbol" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/folding_ranges.rb b/lib/ruby_lsp/requests/folding_ranges.rb index 8e9945184..149e92391 100644 --- a/lib/ruby_lsp/requests/folding_ranges.rb +++ b/lib/ruby_lsp/requests/folding_ranges.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/folding_ranges" +require "ruby_lsp/listeners/folding_ranges" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/hover.rb b/lib/ruby_lsp/requests/hover.rb index 44cffc1e6..27c9aa537 100644 --- a/lib/ruby_lsp/requests/hover.rb +++ b/lib/ruby_lsp/requests/hover.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/hover" +require "ruby_lsp/listeners/hover" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/inlay_hints.rb b/lib/ruby_lsp/requests/inlay_hints.rb index 55a97ff05..c5b115179 100644 --- a/lib/ruby_lsp/requests/inlay_hints.rb +++ b/lib/ruby_lsp/requests/inlay_hints.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/inlay_hints" +require "ruby_lsp/listeners/inlay_hints" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/semantic_highlighting.rb b/lib/ruby_lsp/requests/semantic_highlighting.rb index f5754195d..2347c921a 100644 --- a/lib/ruby_lsp/requests/semantic_highlighting.rb +++ b/lib/ruby_lsp/requests/semantic_highlighting.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/semantic_highlighting" +require "ruby_lsp/listeners/semantic_highlighting" module RubyLsp module Requests diff --git a/lib/ruby_lsp/requests/signature_help.rb b/lib/ruby_lsp/requests/signature_help.rb index 5d56dc5fc..092759f7b 100644 --- a/lib/ruby_lsp/requests/signature_help.rb +++ b/lib/ruby_lsp/requests/signature_help.rb @@ -1,7 +1,7 @@ # typed: strict # frozen_string_literal: true -require_relative "../listeners/signature_help" +require "ruby_lsp/listeners/signature_help" module RubyLsp module Requests