Skip to content
Open
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
1 change: 1 addition & 0 deletions packages/core/src/v1/config/lsp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ export const builtinServerIds = [
"tinymist",
"haskell-language-server",
"julials",
"marksman",
]

export const requiresExtensionsForCustomServers = Schema.makeFilter<
Expand Down
17 changes: 17 additions & 0 deletions packages/opencode/src/lsp/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1981,3 +1981,20 @@ export const JuliaLS: Info = {
}
},
}

export const Marksman: Info = {
id: "marksman",
extensions: [".md", ".markdown"],
root: NearestRoot([".git", ".marksman.toml"]),
async spawn(root) {
const bin = which("marksman")
if (!bin) {
return
}
return {
process: spawn(bin, ["server"], {
cwd: root,
}),
}
},
}
1 change: 1 addition & 0 deletions packages/web/src/content/docs/lsp.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ OpenCode comes with several built-in LSP servers for popular languages:
| julials | .jl | `julia` and `LanguageServer.jl` installed |
| kotlin-ls | .kt, .kts | Auto-installs for Kotlin projects |
| lua-ls | .lua | Auto-installs for Lua projects |
| marksman | .md, .markdown | `marksman` command available |
| nixd | .nix | `nixd` command available |
| ocaml-lsp | .ml, .mli | `ocamllsp` command available |
| oxlint | .ts, .tsx, .js, .jsx, .mjs, .cjs, .mts, .cts, .vue, .astro, .svelte | `oxlint` dependency in project |
Expand Down
Loading