Skip to content

Lazy Extra Typst uses outdated Typst Version #176

Description

@iljusderma

With the used lsp configuration, an older typst/tinymist version 0.13.1 is used. The current one is 0.14.2

I changed the lsp config in this way so that it is forced to use my tinymist version.

{
"neovim/nvim-lspconfig",
opts = {
    servers = {
      tinymist = {
        cmd = { vim.fn.exepath("tinymist") }, -- or full path to the tinymist server executable
        keys = {
          {
            "<leader>cP",
            function()
              local buf_name = vim.api.nvim_buf_get_name(0)
              local file_name = vim.fn.fnamemodify(buf_name, ":t")
              LazyVim.lsp.execute({
                title = "Pin Main",
                filter = "tinymist",
                command = "tinymist.pinMain",
                arguments = { buf_name },
              })
              LazyVim.info("Tinymist: Pinned " .. file_name)
            end,
            desc = "Pin main file",
          },
        },
        single_file_support = true, -- Fixes LSP attachment in non-Git directories
        settings = {
          formatterMode = "typstyle",
          typst = { path = vim.fn.exepath("typst") }, -- if server accepts this
        },
      },
    },
  },

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions