mirror of
https://github.com/Ascyii/telekasten.nvim.git
synced 2026-01-01 06:14:23 -05:00
telekasten, take over my home!
This commit is contained in:
@@ -25,6 +25,10 @@ local M = {}
|
||||
|
||||
M.Cfg = {
|
||||
home = home,
|
||||
|
||||
-- if true, telekasten will be enabled when opening a note within the configured home
|
||||
take_over_my_home = true,
|
||||
|
||||
dailies = home .. "/" .. "daily",
|
||||
weeklies = home .. "/" .. "weekly",
|
||||
templates = home .. "/" .. "templates",
|
||||
@@ -1591,6 +1595,10 @@ local function Setup(cfg)
|
||||
-- setting the syntax moved into plugin/telekasten.vim
|
||||
-- and does not work
|
||||
|
||||
if M.Cfg.take_over_my_home == true then
|
||||
vim.cmd('au BufEnter ' .. M.Cfg.home .. '/*' .. M.Cfg.extension .. ' set ft=telekasten')
|
||||
end
|
||||
|
||||
if debug then
|
||||
print("Resulting config:")
|
||||
print("-----------------")
|
||||
|
||||
Reference in New Issue
Block a user