Moved settings and keymaps around. Created a proper nvim-mapper file. Added dracula back in. Emptied the highest level init.lua

This commit is contained in:
Norm Rasmussen
2023-06-26 21:09:20 -04:00
parent 88c1e905aa
commit 8b13ced135
31 changed files with 185 additions and 529 deletions

View File

@ -13,147 +13,7 @@ vim.opt.rtp:prepend(lazypath)
vim.g.mapleader = ','
vim.g.localmapleader = ','
require('core/keymaps')
require('core/settings')
require('lazy').setup('plugins')
require('keymaps')
-- General Neovim settings and configuration
-----------------------------------------------------------
-----------------------------------------------------------
-- Neovim API aliases
-----------------------------------------------------------
local fn = vim.fn -- Call Vim functions
local cmd = vim.cmd -- Execute Vim commands
local exec = vim.api.nvim_exec -- Execute Vimscript
local g = vim.g -- Global variables
local opt = vim.opt -- Set options (global/buffer/windows-scoped)
local o = vim.o
-----------------------------------------------------------
-- General
-----------------------------------------------------------
g.mapleader = ',' -- Change leader to a comma
opt.mouse = 'a' -- Enable mouse support
opt.clipboard = 'unnamedplus' -- Copy/paste to system clipboard
opt.swapfile = false -- Don't use swapfile
opt.shadafile = "NONE"
opt.shadafile = ""
opt.shell = "/bin/zsh"
opt.updatetime = 200
opt.cursorline = true
g.markdown_folding = 1
opt.spell=true
opt.spelllang = 'en_us'
cmd [[ autocmd BufWritePre * :%s/\s\+$//e ]]
-- vim.api.nvim_set_hl(0, "ColorColumn", {guibg=lightmagenta})
-----------------------------------------------------------
-- Neovim UI
-----------------------------------------------------------
opt.number = true -- Show line number
opt.relativenumber = true -- Show Current Line with Relative numbers above and below cursor.
opt.showmatch = true -- Highlight matching parenthesis
opt.foldmethod = 'syntax' -- Enable folding (default 'foldmarker')
opt.colorcolumn = '120' -- Line length marker at 80 columns
opt.textwidth = 120
opt.splitright = true -- Vertical split to the right
opt.splitbelow = true -- Horizontal split to the bottom
opt.ignorecase = true -- Ignore case letters when search
opt.smartcase = true -- Ignore lowercase for the whole pattern
opt.linebreak = true -- Wrap on word boundary
opt.signcolumn = 'yes:2' -- Signs column always on, minimum 2.
opt.wrap = true
-----------------------------------------------------------
-- Memory, CPU
-----------------------------------------------------------
opt.hidden = true -- Enable background buffers
opt.history = 100 -- Remember N lines in historma:y
opt.lazyredraw = true -- Faster scrolling
opt.synmaxcol = 240 -- Max column for syntax highlight
-----------------------------------------------------------
-- Colorscheme
-----------------------------------------------------------
opt.termguicolors = true -- Enable 24-bit RGB colors
cmd[[colorscheme dracula]]
-----------------------------------------------------------
-- Tabs, indent
-----------------------------------------------------------
opt.expandtab = true -- Use spaces instead of tabs
opt.shiftwidth = 1 -- Shift 4 spaces when tab
opt.tabstop = 1 -- 1 tab == 4 spaces
opt.smartindent = true -- Autoindent new lines
-----------------------------------------------------------
-- Glow Settings
-----------------------------------------------------------
g.glow_binary_path = '/bin'
g.glow_border = 'rounded'
g.glow_width = 120
g.glow_use_pager = true
g.glow_style = 'dark'
-----------------------------------------------------------
-- MKDX Settings, mkdx#settings.
-----------------------------------------------------------
-- 2 spaces for selected filetypes
cmd [[
autocmd FileType md,liquid,xml,html,xhtml,css,scss,javascript,lua,yaml setlocal shiftwidth=2 tabstop=8 noexpandtab
]]
local disabled_built_ins = {
"netrw",
"netrwPlugin",
"netrwSettings",
"netrwFileHandlers",
"gzip",
"zip",
"zipPlugin",
"tar",
"tarPlugin",
"getscript",
"getscriptPlugin",
"vimball",
"vimballPlugin",
"2html_plugin",
"logipat",
"rrhelper",
"spellfile_plugin",
"matchit"
}
for _, plugin in pairs(disabled_built_ins) do
vim.g["loaded_" .. plugin] = 1
end
--[[
Deletes all trailing whitespaces in a file if it's not binary nor a diff.
]]--
function _G.trim_trailing_whitespaces()
if not o.binary and o.filetype ~= 'diff' then
local current_view = fn.winsaveview()
cmd([[keeppatterns %s/\s\+$//e]])
fn.winrestview(current_view)
end
end
-- see https://github.com/hrsh7th/nvim-cmp/wiki/Menu-Appearance#how-to-add-visual-studio-code-dark-theme-colors-to-the-menu
vim.cmd[[
highlight! link CmpItemMenu Comment
" gray
highlight! CmpItemAbbrDeprecated guibg=NONE gui=strikethrough guifg=#808080
" blue
highlight! CmpItemAbbrMatch guibg=NONE guifg=#569CD6
highlight! CmpItemAbbrMatchFuzzy guibg=NONE guifg=#569CD6
" light blue
highlight! CmpItemKindVariable guibg=NONE guifg=#9CDCFE
highlight! CmpItemKindInterface guibg=NONE guifg=#9CDCFE
highlight! CmpItemKindText guibg=NONE guifg=#9CDCFE
" pink
highlight! CmpItemKindFunction guibg=NONE guifg=#C586C0
highlight! CmpItemKindMethod guibg=NONE guifg=#C586C0
" front
highlight! CmpItemKindKeyword guibg=NONE guifg=#D4D4D4
highlight! CmpItemKindProperty guibg=NONE guifg=#D4D4D4
highlight! CmpItemKindUnit guibg=NONE guifg=#D4D4D4
]]

View File

@ -1,67 +1,25 @@
{
"LuaSnip": { "branch": "master", "commit": "500981ff6cefc7343e3959ef0f939bd0bfd49ba9" },
"LuaSnip": { "branch": "master", "commit": "c7984d1cca3d8615e4daefc196597872a0b8d590" },
"alpha-nvim": { "branch": "main", "commit": "9e33db324b8bb7a147bce9ea5496686ee859461d" },
"auto-hlsearch.nvim": { "branch": "main", "commit": "8f28246d53e9478717ca3b51c8112083fbebd7e3" },
"barbar.nvim": { "branch": "master", "commit": "b8ca6076f75e49cca1fa0288c080f3d10ec2152c" },
"cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" },
"cmp-cmdline": { "branch": "main", "commit": "8ee981b4a91f536f52add291594e89fb6645e451" },
"cmp-nvim-lsp": { "branch": "main", "commit": "0e6b2ed705ddcff9738ec4ea838141654f12eeef" },
"cmp-nvim-lsp": { "branch": "main", "commit": "44b16d11215dce86f253ce0c30949813c0a90765" },
"cmp-nvim-lsp-signature-help": { "branch": "main", "commit": "3d8912ebeb56e5ae08ef0906e3a54de1c66b92f1" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp-spell": { "branch": "master", "commit": "60584cb75e5e8bba5a0c9e4c3ab0791e0698bffa" },
"cmp_luasnip": { "branch": "master", "commit": "18095520391186d634a0045dacaa346291096566" },
"deadcolumn.nvim": { "branch": "master", "commit": "b9b5e237371ae5379e280e4df9ecf62e4bc8d7a5" },
"distant.nvim": { "branch": "v0.2", "commit": "9dd21f8fa25795e56756e1ea27a1586ceee35582" },
"feline.nvim": { "branch": "master", "commit": "d48b6f92c6ccdd6654c956f437be49ea160b5b0c" },
"friendly-snippets": { "branch": "main", "commit": "b71d1ddc30a10ce0474156f7ee93bc9006d0cd74" },
"gitsigns.nvim": { "branch": "main", "commit": "4455bb5364d29ff86639dfd5533d4fe4b48192d4" },
"glow.nvim": { "branch": "main", "commit": "bbd0473d72a45094495ee5600b5577823543eefe" },
"gitsigns.nvim": { "branch": "main", "commit": "a36bc3360d584d39b4fb076d855c4180842d4444" },
"headlines.nvim": { "branch": "master", "commit": "ddef41b2664f0ce25fe76520d708e2dc9dfebd70" },
"indent-blankline.nvim": { "branch": "master", "commit": "7075d7861f7a6bbf0de0298c83f8a13195e6ec01" },
"lazy.nvim": { "branch": "main", "commit": "678179543e0d27650c328d8659f2c2cab4d854ef" },
"lsp-colors.nvim": { "branch": "main", "commit": "2bbe7541747fd339bdd8923fc45631a09bb4f1e5" },
"lualine.nvim": { "branch": "master", "commit": "05d78e9fd0cdfb4545974a5aa14b1be95a86e9c9" },
"markdown-preview.nvim": { "branch": "master", "commit": "02cc3874738bc0f86e4b91f09b8a0ac88aef8e96" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "5230617372e656d4a2e1e236e03bf7e7b4b97273" },
"mason.nvim": { "branch": "main", "commit": "7d7efc738e08fc5bee822857db45cb6103f0b0c1" },
"mini.comment": { "branch": "main", "commit": "877acea5b2a32ff55f808fc0ebe9aa898648318c" },
"mini.fuzzy": { "branch": "stable", "commit": "295763d73cbf580c27a4419364c47b09fc82e0f4" },
"mini.move": { "branch": "main", "commit": "3afd39873eb9171684e554a214c055482444a47d" },
"mini.pairs": { "branch": "stable", "commit": "963b800d0524eadd297199207011b98684205ada" },
"mini.surround": { "branch": "main", "commit": "eeaf96562947f75afa51a6266e066529369ca7ef" },
"mini.trailspace": { "branch": "main", "commit": "c41ab1035d184ff20c1aebd76639320c055afebe" },
"mkdnflow.nvim": { "branch": "main", "commit": "5a9768fe09c614600fd2881f29c5cedf931f3e36" },
"moonfly": { "branch": "master", "commit": "8f2b6b97ae5ba1090229c4eb842cbc912d7ffb65" },
"neoscroll.nvim": { "branch": "master", "commit": "d7601c26c8a183fa8994ed339e70c2d841253e93" },
"neovim": { "branch": "main", "commit": "6b7b38bbb3dac648dbf81f2728ce1101f476f920" },
"nightfox.nvim": { "branch": "main", "commit": "77aa7458d2b725c2d9ff55a18befe1b891ac473e" },
"null-ls.nvim": { "branch": "main", "commit": "a138b14099e9623832027ea12b4631ddd2a49256" },
"nvim": { "branch": "main", "commit": "2df7036c5c303c9184869936e40ca18935e4afcb" },
"nvim-cmp": { "branch": "main", "commit": "09ff53ff579cfa3368f8051b0dbe88406891aabe" },
"nvim-dap": { "branch": "master", "commit": "7c1d47cf7188fc31acdf951f9eee22da9d479152" },
"nvim-dap-python": { "branch": "master", "commit": "37b4cba02e337a95cb62ad1609b3d1dccb2e5d42" },
"nvim-dap-ui": { "branch": "master", "commit": "c020f660b02772f9f3d11f599fefad3268628a9e" },
"nvim-lspconfig": { "branch": "master", "commit": "08f1f347c718e945c3b1712ebb68c6834182cf3a" },
"lazy.nvim": { "branch": "main", "commit": "4c8b625bc873ca76b76eee0c28c98f1f7148f17f" },
"null-ls.nvim": { "branch": "main", "commit": "bbaf5a96913aa92281f154b08732be2f57021c45" },
"nvim-cmp": { "branch": "main", "commit": "e1f1b40790a8cb7e64091fb12cc5ffe350363aa0" },
"nvim-lspconfig": { "branch": "master", "commit": "b6b34b9acf84949f0ac1c00747765e62b81fb38d" },
"nvim-mapper": { "branch": "main", "commit": "baad83aad85d420cce24dd60106114421ed59039" },
"nvim-notify": { "branch": "master", "commit": "ea9c8ce7a37f2238f934e087c255758659948e0f" },
"nvim-tree.lua": { "branch": "master", "commit": "034511714bacfadc5008e49f73fcef67e5613840" },
"nvim-treesitter": { "branch": "master", "commit": "f9d701176cb9a3e206a4c690920a8993630c3ec8" },
"nvim-web-devicons": { "branch": "master", "commit": "2a125024a137677930efcfdf720f205504c97268" },
"plenary.nvim": { "branch": "master", "commit": "499e0743cf5e8075cd32af68baa3946a1c76adf1" },
"popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" },
"sidebar.nvim": { "branch": "main", "commit": "990ce5f562c9125283ccac5473235b1a56fea6dc" },
"starry.nvim": { "branch": "master", "commit": "9c4f8669acb302300e1495d4b1f1e618524a48f4" },
"styler.nvim": { "branch": "main", "commit": "58d0d12191adee41fce7ef20d46d1203efa0d11e" },
"symbols-outline.nvim": { "branch": "master", "commit": "512791925d57a61c545bc303356e8a8f7869763c" },
"telescope-file-browser.nvim": { "branch": "master", "commit": "fc70589a93d7bb42f4671ad75c8628a29995bcbe" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "9bc8237565ded606e6c366a71c64c0af25cd7a50" },
"nvim-treesitter": { "branch": "master", "commit": "d49ba798c95398e62321b40041e8ac4654fea251" },
"nvim-web-devicons": { "branch": "master", "commit": "9ab9b0b894b2388a9dbcdee5f00ce72e25d85bf9" },
"plenary.nvim": { "branch": "master", "commit": "36aaceb6e93addd20b1b18f94d86aecc552f30c4" },
"styler.nvim": { "branch": "main", "commit": "d5b7e43af4fdaa06e4175c84f4f57b633ae7e6ff" },
"telescope-live-grep-args.nvim": { "branch": "master", "commit": "0f75ea809c46af8997c64f49c52e3c641d887885" },
"telescope.nvim": { "branch": "master", "commit": "c1a2af0af69e80e14e6b226d3957a064cd080805" },
"tmux.nvim": { "branch": "main", "commit": "03e28fdaa2ef54b975ba1930f1e69b5e231dedc9" },
"todo-comments.nvim": { "branch": "main", "commit": "09b0b17d824d2d56f02ff15967e8a2499a89c731" },
"tokyonight.nvim": { "branch": "main", "commit": "161114bd39b990995e08dbf941f6821afbdcd666" },
"trouble.nvim": { "branch": "main", "commit": "2af0dd9767526410c88c628f1cbfcb6cf22dd683" },
"vim-arduino": { "branch": "master", "commit": "b2573b094ec301f2874b7ae3ec0e8806f8fb5e0e" },
"vim-wakatime": { "branch": "master", "commit": "018fa9a80c27ccf2a8967b9e27890372e5c2fb4f" },
"which-key.nvim": { "branch": "main", "commit": "e271c28118998c93a14d189af3395812a1aa646c" }
"telescope.nvim": { "branch": "master", "commit": "c1a2af0af69e80e14e6b226d3957a064cd080805" }
}

View File

@ -0,0 +1,22 @@
-----------------------------------------------------------
-- Keymaps of Neovim and installed plugins
-----------------------------------------------------------
local map = vim.api.nvim_set_keymap
local default_opts = { noremap = true, silent = true }
-- Fast saving with <leader> and s
map('n', '<leader>s', ':w<CR>', default_opts)
map('n', '<leader>a', ':w|:luafile %<CR>', default_opts)
map('n', '<leader>aa', ':w|:luafile %<CR> |:PackerSync<CR>', default_opts)
map('i', '<leader>s', '<C-c>:w<CR>', default_opts)
-- Python Script that saves the file & moves Todos to my Todolist.
map('n', '<leader>sd', ':w|:! python3 ~/Documents/Northpass/Scripts/TodoMD/todo.py %<CR>', default_opts)
-- Neovim Tab Navgation via Vem-Tabline
map('n', '<leader>t', ':tabnew<CR>', default_opts)
map('n', '<leader>e', ':bnext<CR>', default_opts)
map('n', '<leader>w', ':bprev<CR>', default_opts)
map('n', '<leader>d', ':bdelete<CR>', default_opts)
map('n', '<leader>r', '<Plug>vem_move_buffer_right', default_opts)
map('n', '<leader>q', '<Plug>vem_move_buffer_left', default_opts)

View File

@ -1,14 +1,15 @@
-----------------------------------------------------------
-- General Neovim settings and configuration
-----------------------------------------------------------
-----------------------------------------------------------
-- Neovim API aliases
-----------------------------------------------------------
local fn = vim.fn -- Call Vim functions
local cmd = vim.cmd -- Execute Vim commands
local fn = vim.fn -- Call Vim functions
local cmd = vim.cmd -- Execute Vim commands
local exec = vim.api.nvim_exec -- Execute Vimscript
local g = vim.g -- Global variables
local opt = vim.opt -- Set options (global/buffer/windows-scoped)
local g = vim.g -- Global variables
local opt = vim.opt -- Set options (global/buffer/windows-scoped)
local o = vim.o
-----------------------------------------------------------
@ -27,23 +28,22 @@ g.markdown_folding = 1
opt.spell=true
opt.spelllang = 'en_us'
cmd [[ autocmd BufWritePre * :%s/\s\+$//e ]]
vim.api.nvim_set_hl(0, "ColorColumn", {guibg=lightmagenta})
o.showtabline = 2
--vim.api.nvim_set_hl(0, "ColorColumn", {guibg=lightmagenta})
-----------------------------------------------------------
-- Neovim UI
-----------------------------------------------------------
opt.number = true -- Show line number
opt.relativenumber = true -- Show Current Line with Relative numbers above and below cursor.
opt.showmatch = true -- Highlight matching parenthesis
opt.foldmethod = 'syntax' -- Enable folding (default 'foldmarker')
opt.colorcolumn = '100' -- Line length marker at 80 columns
opt.textwidth = 100
opt.foldmethod = "syntax" -- Enable folding (default 'foldmarker')
opt.cc = '+1,+2,+3' -- Line length marker at 80 columns
opt.tw = 80
opt.splitright = true -- Vertical split to the right
opt.splitbelow = true -- Horizontal split to the bottom
opt.ignorecase = true -- Ignore case letters when search
opt.smartcase = true -- Ignore lowercase for the whole pattern
opt.linebreak = true -- Wrap on word boundary
opt.signcolumn = 'yes:2' -- Signs column always on, minimum 2.
opt.signcolumn = 'yes:1' -- Signs column always on, minimum 2.
opt.wrap = true
-----------------------------------------------------------
@ -57,21 +57,22 @@ opt.synmaxcol = 240 -- Max column for syntax highlight
-- Colorscheme
-----------------------------------------------------------
opt.termguicolors = true -- Enable 24-bit RGB colors
cmd[[colorscheme dracula]]
-----------------------------------------------------------
-- Tabs, indent
-----------------------------------------------------------
opt.expandtab = true -- Use spaces instead of tabs
opt.shiftwidth = 1 -- Shift 4 spaces when tab
opt.tabstop = 1 -- 1 tab == 4 spaces
opt.shiftwidth = 4 -- Shift 4 spaces when tab
opt.tabstop = 4 -- 1 tab == 4 spaces
opt.smartindent = true -- Autoindent new lines
-----------------------------------------------------------
-- Glow Settings
-----------------------------------------------------------
g.glow_binary_path = '/bin'
g.glow_border = 'rounded'
g.glow_width = 100
g.glow_width = 120
g.glow_use_pager = true
g.glow_style = 'light'
g.glow_style = 'dark'
-----------------------------------------------------------
-- MKDX Settings, mkdx#settings.
-----------------------------------------------------------
@ -116,3 +117,25 @@ function _G.trim_trailing_whitespaces()
fn.winrestview(current_view)
end
end
-- see https://github.com/hrsh7th/nvim-cmp/wiki/Menu-Appearance#how-to-add-visual-studio-code-dark-theme-colors-to-the-menu
vim.cmd[[
highlight! link CmpItemMenu Comment
" gray
highlight! CmpItemAbbrDeprecated guibg=NONE gui=strikethrough guifg=#808080
" blue
highlight! CmpItemAbbrMatch guibg=NONE guifg=#569CD6
highlight! CmpItemAbbrMatchFuzzy guibg=NONE guifg=#569CD6
" light blue
highlight! CmpItemKindVariable guibg=NONE guifg=#9CDCFE
highlight! CmpItemKindInterface guibg=NONE guifg=#9CDCFE
highlight! CmpItemKindText guibg=NONE guifg=#9CDCFE
" pink
highlight! CmpItemKindFunction guibg=NONE guifg=#C586C0
highlight! CmpItemKindMethod guibg=NONE guifg=#C586C0
" front
highlight! CmpItemKindKeyword guibg=NONE guifg=#D4D4D4
highlight! CmpItemKindProperty guibg=NONE guifg=#D4D4D4
highlight! CmpItemKindUnit guibg=NONE guifg=#D4D4D4
]]

View File

@ -1,126 +0,0 @@
-----------------------------------------------------------
-- Keymaps of Neovim and installed plugins
-----------------------------------------------------------
local map = vim.api.nvim_set_keymap
local default_opts = { noremap = true, silent = true }
-- Fast saving with <leader> and s
map('n', '<leader>s', ':w<CR>', default_opts)
map('n', '<leader>a', ':w|:luafile %<CR>', default_opts)
map('n', '<leader>aa', ':w|:luafile %<CR> |:PackerSync<CR>', default_opts)
map('i', '<leader>s', '<C-c>:w<CR>', default_opts)
-- Python Script that saves the file & moves Todos to my Todolist.
map('n', '<leader>sd', ':w|:! python3 ~/Documents/Northpass/Scripts/TodoMD/todo.py %<CR>', default_opts)
-- Neovim Tab Navgation via Vem-Tabline
map('n', '<leader>t', ':tabnew<CR>', default_opts)
map('n', '<leader>e', ':bnext<CR>', default_opts)
map('n', '<leader>w', ':bprev<CR>', default_opts)
map('n', '<leader>d', ':bdelete<CR>', default_opts)
map('n', '<leader>r', '<Plug>vem_move_buffer_right', default_opts)
map('n', '<leader>q', '<Plug>vem_move_buffer_left', default_opts)
-----------------------------------------------------------
-- Applications and Plugins shortcuts
-----------------------------------------------------------
-----------------------------------------------------------
-- Telescope Keymaps
-----------------------------------------------------------
-- For Neovim >= 0.7.0
Mapper = require("nvim-mapper")
local M = Mapper.map
local default_opts = {noremap=true, silent=true}
-- Sidebar
M('n', '<leader>n', ':SidebarNvimToggle<CR>', default_opts,
"Sidebar Toggle", "sidebar-toggle", "Open or Close Sidebar"
)
M('n', '<leader>q', ':SidebarNvimUpdate<CR>', default_opts,
"Sidebar Update", "sidebar-update", "Refresh the Sidebar"
)
--[[ Sidebar Resize
M('n', '<leader>=', ':SidebarNvimResize +1<CR>', default_opts,
"Sidebar +1", "sidebar-plus1", "Sidebar Bigger by one"
)
M('n', '<leader>-', ':SidebarNvimResize -1<CR>', default_opts,
"Sidebar -1", "sidebar-minus1", "Sidebar Smaller by one"
)
M('n', '<leader>==', ':SidebarNvimResize +10<CR>', default_opts,
"Sidebar +10", "sidebar-plus10", "Sidebar Bigger by 10"
)
M('n', '<leader>--', ':SidebarNvimResize -10<CR>', default_opts,
"Sidebar -10", "sidebar-minus10", "Sidebar Smaller by 10"
)--]]
-- Lazy Git
M('n', '<leader>lg', ":LazyGit<CR>", default_opts,
"Lazy Git", "lazy-git", "Show Lazy Git"
)
-- Markdown Preview Toggle
M('n', '<leader>P', ":MarkdownPreview<CR>", default_opts,
"Markdown Preview", "md_preview", "Display Markdown preview in browser"
)
-- Telescope Options
M('n', '<leader>ff', ':Telescope find_files<CR>', default_opts,
"Find Files", "find-files", "Find Files in Telescope pop-up"
)
M('n', '<leader>fg', ':Telescope live_grep<CR>', default_opts,
"Live Grep", "live-grep", "Grep Files in Telescope pop-up"
)
M('n', '<leader>fb', ':Telescope buffers<CR>', default_opts,
"Buffers", "buffers", "See Buffers in Telescope pop-up"
)
M('n', '<leader>fe', ":Telescope file_browser<CR>", default_opts,
"Telescope Files", "telescope-file-browser", "Find files and directories in telescope"
)
M('n', '<C-t>', "@t<CR>", default_opts,
"Add Todo", "todo_todo", "Add To-do/Task to the beginning of the line"
)
M('n', '<C-s>', "@s<CR>", default_opts,
"Add Solutions Engineering", "todo_seng", "Add Solutions Engineering to the beginning of the line"
)
M('n', '<C-f>', "@f<CR>", default_opts,
"Add Feature", "add_feat", "Add Feature Request tag to the beginning of the line. "
)
M( 'n', '<C-x>', "@c<CR>", default_opts,
"Replace with Complete", "add_complete", "Replace tag with Complete tag at beginning of the line."
)
M('n', '<C-r>', "@w<CR>", default_opts,
"Add Warning/Error", "add_error", "Add Warning/Error tag at the beginning of the line."
)
M('n', '<leader>ce', ":TodoTrouble keywords=TODO<CR> | :resize +10<CR>", default_opts,
"Show Todo Tags", "show_todos", "Show Todo Tags."
)
M('n', '<leader>cf', ":TodoTrouble keywords=FEAT<CR>", default_opts,
"Show Feature Tags", "show_features", "Show Feature Requests."
)
M('n', '<leader>cq', ":TodoTrouble keywords=ERROR, WARN<CR>", default_opts,
"Show Warning Tags", "show_warnings", "Show Errors Tags."
)
M('n', '<leader>b', ":! black %<CR>", default_opts,
"Black Formatting", "black_current_file", "Use Black Formatting on Current File."
)
M('n', '<leader>m', ":! markdownlint -f %<CR>", default_opts,
"Markdownlint", "md_lint_format", "Use mdlint Formatting on Current File."
)
M('n', '<leader>r30', ":resize 30<CR>", default_opts,
"Resize30", "resize_30", "Resize Window to #30"
)

View File

@ -23,11 +23,11 @@ return {
{ 'neovim/nvim-lspconfig' },
-- Manage all your Keymaps!
{
"gregorias/nvim-mapper",
config = function() require("nvim-mapper").setup{} end,
before = "telescope.nvim"
},
-- {
-- "gregorias/nvim-mapper",
-- config = function() require("nvim-mapper").setup{} end,
-- before = "telescope.nvim"
-- },
{
'L3MON4D3/LuaSnip', version = "1.2.1",
@ -106,8 +106,11 @@ return {
-- Top Right Notify Pop Up
'rcarriga/nvim-notify',
-- echasnovski Mini Modules (Selected)
{
------------------------------------------------------------
-- echasnovski's Minis get a section of their own...
------------------------------------------------------------
{
'echasnovski/mini.comment', version = '*',
config = function()
require('mini.comment').setup()
@ -157,7 +160,6 @@ return {
},
-----------------------------------------------------------
-- Markdown Plugins
------------------------------------------------------------
@ -234,6 +236,7 @@ return {
'lukas-reineke/indent-blankline.nvim',
'folke/lsp-colors.nvim',
'Mofiqul/dracula.nvim'
'karb94/neoscroll.nvim',
-- Allow Popups for Telescope etc

View File

@ -16,7 +16,7 @@ return {
-- null_ls.builtins.diagnostics.pylama,
null_ls.builtins.formatting.black,
-- null_ls.builtins.diagnostics.pylint,
null_ls.builtins.diagnostics.pycodestyle.with({ extra_args = { "--max-line-length=150" }}),
null_ls.builtins.diagnostics.pycodestyle.with({ extra_args = { "--max-line-length=120" }}),
},
})
end

View File

@ -0,0 +1,85 @@
-- For Neovim >= 0.7.0
return {
"gregorias/nvim-mapper",
before = "telescope.nvim",
config = function()
Mapper = require("nvim-mapper")
local M = Mapper.map
local default_opts = {noremap=true, silent=true}
M('n', '<leader>n', ':SidebarNvimToggle<CR>', default_opts,
"Sidebar Toggle", "sidebar-toggle", "Open or Close Sidebar"
)
M('n', '<leader>q', ':SidebarNvimUpdate<CR>', default_opts,
"Sidebar Update", "sidebar-update", "Refresh the Sidebar"
)
-- Lazy Git
M('n', '<leader>lg', ":LazyGit<CR>", default_opts,
"Lazy Git", "lazy-git", "Show Lazy Git"
)
-- Markdown Preview Toggle
M('n', '<leader>P', ":MarkdownPreview<CR>", default_opts,
"Markdown Preview", "md_preview", "Display Markdown preview in browser"
)
-- Telescope Options
M('n', '<leader>ff', ':Telescope find_files<CR>', default_opts,
"Find Files", "find-files", "Find Files in Telescope pop-up"
)
M('n', '<leader>fg', ':Telescope live_grep<CR>', default_opts,
"Live Grep", "live-grep", "Grep Files in Telescope pop-up"
)
M('n', '<leader>fb', ':Telescope buffers<CR>', default_opts,
"Buffers", "buffers", "See Buffers in Telescope pop-up"
)
M('n', '<leader>fe', ":Telescope file_browser<CR>", default_opts,
"Telescope Files", "telescope-file-browser", "Find files and directories in telescope"
)
M('n', '<C-t>', "@t<CR>", default_opts,
"Add Todo", "todo_todo", "Add To-do/Task to the beginning of the line"
)
M('n', '<C-s>', "@s<CR>", default_opts,
"Add Solutions Engineering", "todo_seng", "Add Solutions Engineering to the beginning of the line"
)
M('n', '<C-f>', "@f<CR>", default_opts,
"Add Feature", "add_feat", "Add Feature Request tag to the beginning of the line. "
)
M( 'n', '<C-x>', "@c<CR>", default_opts,
"Replace with Complete", "add_complete", "Replace tag with Complete tag at beginning of the line."
)
M('n', '<C-r>', "@w<CR>", default_opts,
"Add Warning/Error", "add_error", "Add Warning/Error tag at the beginning of the line."
)
M('n', '<leader>ce', ":TodoTrouble keywords=TODO<CR> | :resize +10<CR>", default_opts,
"Show Todo Tags", "show_todos", "Show Todo Tags."
)
M('n', '<leader>cf', ":TodoTrouble keywords=FEAT<CR>", default_opts,
"Show Feature Tags", "show_features", "Show Feature Requests."
)
M('n', '<leader>cq', ":TodoTrouble keywords=ERROR, WARN<CR>", default_opts,
"Show Warning Tags", "show_warnings", "Show Errors Tags."
)
M('n', '<leader>b', ":! black %<CR>", default_opts,
"Black Formatting", "black_current_file", "Use Black Formatting on Current File."
)
M('n', '<leader>m', ":! markdownlint -f %<CR>", default_opts,
"Markdownlint", "md_lint_format", "Use mdlint Formatting on Current File."
)
M('n', '<leader>r30', ":resize 30<CR>", default_opts,
"Resize30", "resize_30", "Resize Window to #30"
)
end,
}

View File

@ -309,3 +309,5 @@ event
event
MJ
Wix
cateogries
cateogries