Commit graph

8 commits

Author SHA1 Message Date
Marc Huisinga
7ff7cf9b5a
feat: per-package server options (#2858)
This PR adds per-package server options to resolve #2455. It is based on
the previous work in #2456, but takes a different approach: options are
loaded for the specific file in the file worker when `print-paths` is
called, instead of loading them in the watchdog with a separate Lake
command. This change addresses review comments made in #2456.

In doing so, it introduces two new Lake config fields: 
- `leanOptions`: `-D` flag options that are passed to both the language
server and `lean` when building.
- `moreServerOptions`: `-D` flag options that are passed to the language
server.

Since `print-paths` must also accept a file path to compute the options
for that file, this PR is changing the API for `print-paths`. As there
have been numerous complaints about the name `print-paths`, I also
decided to change it to `setup-file` in this PR, since it would break
compatibility with the old Lake API anyways.

This PR deprecates the Lakefile field `moreServerArgs` in favor of
`moreGlobalServerArgs`, as suggested in the review for #2456.

Fixes #2455

---------

Co-authored-by: digama0 <mcarneir@andrew.cmu.edu>
2023-11-26 13:42:38 +00:00
Mario Carneiro
2f8d20a90d fix: fix test 2022-09-19 13:49:20 -07:00
Leonardo de Moura
3325987be4 chore: fix tests 2022-07-18 23:18:59 -04:00
Wojciech Nawrocki
a8cfbb11bf Revert "chore: fix tests"
This reverts commit c6acd968d7.
2022-05-12 13:22:37 -07:00
Leonardo de Moura
c6acd968d7 chore: fix tests 2022-05-12 08:44:00 -07:00
Leonardo de Moura
7d7c6d8be5 feat: add CompletionItemKind 2021-12-15 11:24:11 -08:00
Leonardo de Moura
5f119cb54f feat: avoid metavariables at CompletionItems
Not sure whether it helps or creates more confusion.
Note that we are still using the `?` prefix for metavariables on the
InfoView and hover info.
2021-10-29 08:01:21 -07:00
Leonardo de Moura
68120b24b8 feat: add docstring to CompletionItem
closes #746
2021-10-28 08:14:40 -07:00