Cheatsheets and debuggin
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
local M = {}
|
||||
|
||||
function M.open(name)
|
||||
local titles = {
|
||||
zsh = 'ZSH Cheat Sheet',
|
||||
bash = 'Bash Cheat Sheet',
|
||||
regex = 'RegExp Cheat Sheet',
|
||||
}
|
||||
|
||||
local path = vim.fn.stdpath 'config' .. '/cheatsheets/' .. name .. '.md'
|
||||
print('Opening cheat sheet: ' .. path)
|
||||
|
||||
require('../helpers').open_file_modal(path, titles[name] or name)
|
||||
end
|
||||
|
||||
return M
|
||||
Reference in New Issue
Block a user