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

Add support for the Lean language #695

Merged
merged 2 commits into from
Nov 14, 2023
Merged

Conversation

GaetanLepage
Copy link
Member

@GaetanLepage GaetanLepage commented Nov 11, 2023

@GaetanLepage GaetanLepage force-pushed the lean branch 2 times, most recently from 897f80c to 6cbc0f8 Compare November 13, 2023 09:23
@GaetanLepage GaetanLepage requested a review from traxys November 13, 2023 09:23
@GaetanLepage GaetanLepage marked this pull request as ready for review November 13, 2023 09:23
plugins/languages/lean.nix Outdated Show resolved Hide resolved
Comment on lines +138 to +145
lean3 = {
showFilter = helpers.defaultNullOpts.mkBool true "";

mouseEvents = helpers.defaultNullOpts.mkBool false ''
Setting this to `true` will simulate mouse events in the Lean 3 infoview, this is buggy
at the moment so you can use the I/i keybindings to manually trigger these.
'';
};
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn this be in the global scope and not in infoview ? (as from the README.rst):

  -- Redirect Lean's stderr messages somehwere (to a buffer by default)
  stderr = {
    enable = true,
    -- height of the window
    height = 5,
    -- a callback which will be called with (multi-line) stderr output
    -- e.g., use:
    --   on_lines = function(lines) vim.notify(lines) end
    -- if you want to redirect stderr to `vim.notify`.
    -- The default implementation will redirect to a dedicated stderr
    -- window.
    on_lines = nil,
  },

  -- Legacy Lean 3 support (on_attach is as above, your LSP handler)
  lsp3 = { on_attach = on_attach },

  -- mouse_events = true will simulate mouse events in the Lean 3 infoview, this is buggy at the moment
  -- so you can use the I/i keybindings to manually trigger these
  lean3 = { mouse_events = false },
}

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is indeed what the documentation suggests, but after looking at the code, this is clearly under infoview.
This isn't the only error I spotted in this documentation section.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed.... I tried to search for a compatibility layer but there does not seem to be any

@GaetanLepage GaetanLepage merged commit 19654ff into nix-community:main Nov 14, 2023
1 check passed
@GaetanLepage GaetanLepage deleted the lean branch November 14, 2023 10:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants