check if fabric-ai and my obsidian vault exists

This commit is contained in:
2026-07-08 16:23:34 -04:00
parent 5471ed7383
commit ce488fce61
3 changed files with 101 additions and 86 deletions
+16 -14
View File
@@ -1,15 +1,17 @@
require('fabric-ai').setup({
-- Default configuration (all optional)
fabric_path = "fabric-ai", -- Path to Fabric CLI
patterns_path = nil, -- Custom patterns dir (auto-detect if nil)
timeout = 300000, -- Command timeout in ms (5 minutes)
window = {
width = 0.8, -- 80% of editor width
height = 0.8, -- 80% of editor height
border = "rounded",
},
})
if vim.fn.executable("fabric-ai") == 1 then
require('fabric-ai').setup({
-- Default configuration (all optional)
fabric_path = "fabric-ai", -- Path to Fabric CLI
patterns_path = nil, -- Custom patterns dir (auto-detect if nil)
timeout = 300000, -- Command timeout in ms (5 minutes)
window = {
width = 0.8, -- 80% of editor width
height = 0.8, -- 80% of editor height
border = "rounded",
},
})
vim.keymap.set({ 'v' }, "<leader>fa", ":'<,'>Fabric<CR>", { desc = "Fabric AI" })
vim.keymap.set({ 'n' }, '<leader>fa', ':Fabric<CR>', { desc = "Fabric AI" })
vim.keymap.set({ 'n' }, '<leader>fu', ':Fabric url<CR>', { desc = "Fabric URL" })
vim.keymap.set({ 'v' }, "<leader>fa", ":'<,'>Fabric<CR>", { desc = "Fabric AI" })
vim.keymap.set({ 'n' }, '<leader>fa', ':Fabric<CR>', { desc = "Fabric AI" })
vim.keymap.set({ 'n' }, '<leader>fu', ':Fabric url<CR>', { desc = "Fabric URL" })
end