Setup
Binary
Download Binary (Linux only)
Linux
wget https://github.com/sylveryte/sylmark/releases/download/v0.7.1/sylmark_linux_amd64
chmod +x sylmark_linux_amd64OR
Build from source
Prerequisites
Linux/Unix
- Clone repo
git clone https://codeberg.org/sylveryte/sylmark.git- Navigate to root of project
cd sylmark- First build sylgraph
cd server/sylgraph && npm i && npm run build- Navigate back to root
cd ../..- Build lsp server using golang
CGO_ENABLED=1 go build- Move your binary from
./sylmarkto desired place eg:~/bin/sylmark
mv ./sylmark ~/bin/Editor
Neovim
- Obtain Build and get path eg:
~/bin/sylmark_linux_amd64 - Add lsp config
vim.lsp.config.sylmark = {
cmd = { "path/to/binary" },
root_markers = { '.sylroot.toml' },
filetypes = { 'markdown' },
on_attach = function(client, bufnr)
vim.api.nvim_create_user_command(
"Daily",
function(args)
local input = args.args
client:exec_cmd({
title = "Show",
command = "show",
arguments = { input }, -- Also works with `vim.NIL`
}, { bufnr = bufnr })
end,
{ desc = 'Open daily note', nargs = "*" }
)
vim.api.nvim_create_user_command(
"Graph",
function(args)
local input = args.args
client:exec_cmd({
title = "Open Graph",
command = "graph",
arguments = { input }, -- Also works with `vim.NIL`
}, { bufnr = bufnr })
end,
{ desc = 'Start graph server and open', nargs = "*" }
)
end
}
vim.lsp.enable({
"sylmark",
})VS Code
Plugin in progress