obsidian working
This commit is contained in:
parent
766f9b43a8
commit
2f06d41f2b
@ -1,3 +1,6 @@
|
||||
# Dependencies
|
||||
wl-clipboard ripgrep
|
||||
|
||||
## Used plugins
|
||||
- https://github.com/folke/lazy.nvim (plugin manager)
|
||||
|
||||
@ -6,9 +9,10 @@
|
||||
- https://github.com/nvim-lualine/lualine.nvim (status bar)
|
||||
|
||||
### Basic utilitiy plugins
|
||||
- https://github.com/nvim-telescope/telescope.nvim (fuzzy finder
|
||||
- https://github.com/nvim-telescope/telescope.nvim (fuzzy finder)
|
||||
- https://github.com/nvim-telescope/telescope-ui-select.nvim (ui for code actions)
|
||||
)
|
||||
- https://github.com/epwalsh/obsidian.nvim (Obsidian in Nvim)
|
||||
|
||||
- https://github.com/nvim-treesitter/nvim-treesitter (tree sitter plugin old)
|
||||
- https://github.com/nvim-neo-tree/neo-tree.nvim (map of filesystem)
|
||||
- https://github.com/christoomey/vim-tmux-navigator (tmux integration)
|
||||
@ -33,7 +37,6 @@
|
||||
## Cool plugins to add
|
||||
|
||||
### Cool plugins to study
|
||||
- https://github.com/epwalsh/obsidian.nvim (Obsidian in Nvim)
|
||||
- https://github.com/Feel-ix-343/markdown-oxide?tab=readme-ov-file (lsp that makes Obsidian from .md)
|
||||
|
||||
## Tutorials foud
|
||||
|
||||
4
init.lua
4
init.lua
@ -18,14 +18,12 @@ vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
require("lazy").setup("plugins") -- packet manager --
|
||||
|
||||
-- local builtin = require("telescope.builtin") -- fuzzy finder --
|
||||
|
||||
local config = require("nvim-treesitter.configs") -- tree sitter plugin config for langs --
|
||||
config.setup({
|
||||
ensure_installed = {
|
||||
"lua", "python",
|
||||
"javascript", "html", "css",
|
||||
"markdown",
|
||||
"markdown", "markdown_inline"
|
||||
},
|
||||
highlight = { enable = true },
|
||||
indent = { enable = true },
|
||||
|
||||
66
lua/plugins/obsidian.lua
Normal file
66
lua/plugins/obsidian.lua
Normal file
@ -0,0 +1,66 @@
|
||||
return {
|
||||
"epwalsh/obsidian.nvim",
|
||||
version = "*", -- recommended, use latest release instead of latest commit
|
||||
lazy = true,
|
||||
ft = "markdown",
|
||||
-- Replace the above line with this if you only want to load obsidian.nvim for markdown files in your vault:
|
||||
event = {
|
||||
-- If you want to use the home shortcut '~' here you need to call 'vim.fn.expand'.
|
||||
-- E.g. "BufReadPre " .. vim.fn.expand "~" .. "/my-vault/*.md"
|
||||
-- refer to `:h file-pattern` for more examples
|
||||
-- "BufReadPre ~/Nextcloud/Notes/*.md",
|
||||
-- "BufNewFile path/to/my-vault/*.md",
|
||||
},
|
||||
dependencies = {
|
||||
-- Required.
|
||||
"nvim-lua/plenary.nvim",
|
||||
-- see below for full list of optional dependencies 👇
|
||||
"hrsh7th/nvim-cmp",
|
||||
},
|
||||
opts = {
|
||||
workspaces = {
|
||||
--{
|
||||
-- name = "Notes",
|
||||
-- path = "~/Nextcloud/Notes",
|
||||
--},
|
||||
{
|
||||
name = "Skola",
|
||||
path = "/home/godot/Nextcloud/Notes/Skola",
|
||||
},
|
||||
{
|
||||
name = "RPG",
|
||||
path = "/home/godot/Nextcloud/Notes/RPG",
|
||||
},
|
||||
{
|
||||
name = "Tech",
|
||||
path = "/home/godot/Nextcloud/Notes/Tech",
|
||||
},
|
||||
},
|
||||
|
||||
mappings = {
|
||||
-- Overrides the 'gf' mapping to work on markdown/wiki links within your vault.
|
||||
["gf"] = {
|
||||
action = function()
|
||||
return require("obsidian").util.gf_passthrough()
|
||||
end,
|
||||
opts = { noremap = false, expr = true, buffer = true },
|
||||
},
|
||||
-- Toggle check-boxes.
|
||||
["<leader>ch"] = {
|
||||
action = function()
|
||||
return require("obsidian").util.toggle_checkbox()
|
||||
end,
|
||||
opts = { buffer = true },
|
||||
},
|
||||
-- Smart action depending on context, either follow link or toggle checkbox.
|
||||
["<cr>"] = {
|
||||
action = function()
|
||||
return require("obsidian").util.smart_action()
|
||||
end,
|
||||
opts = { buffer = true, expr = true },
|
||||
}
|
||||
},
|
||||
|
||||
-- see below for full list of options 👇
|
||||
},
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user