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

Disable jump code action by default #1411

Merged
merged 2 commits into from
Dec 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
# Unreleased

## Fixes

- Deactivate the `jump` code actions by default. Clients can enable them with
the `merlinJumpCodeActions` configuration option. Alternatively a custom
request is provided for ad hoc use of the feature. (#1411)

# 1.20.0

## Features
Expand Down
4 changes: 2 additions & 2 deletions ocaml-lsp-server/src/code_actions.ml
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ let compute server (params : CodeActionParams.t) =
let open_related = Action_open_related.for_uri capabilities doc in
let* merlin_jumps =
match state.configuration.data.merlin_jump_code_actions with
| Some { enable = true } | None -> Action_jump.code_actions doc params capabilities
| Some { enable = false } -> Fiber.return []
| Some { enable = true } -> Action_jump.code_actions doc params capabilities
| Some { enable = false } | None -> Fiber.return []
in
(match Document.syntax doc with
| Ocamllex | Menhir | Cram | Dune ->
Expand Down