zsh vi-mode is ok. multiline command editing only possible once it hits history, though
parent
563c7e8da5
commit
191919bc47
|
@ -1,4 +1,7 @@
|
|||
{
|
||||
"$schema": "https://raw.githubusercontent.com/sumneko/vscode-lua/master/setting/schema.json",
|
||||
"Lua.diagnostics.globals": [
|
||||
"vim",
|
||||
],
|
||||
"Lua.workspace.checkThirdParty": false
|
||||
}
|
||||
}
|
||||
|
|
|
@ -94,6 +94,25 @@ if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
|
|||
endif
|
||||
]])
|
||||
|
||||
-- special terminals, place them at 4 and 5 for ergonomics
|
||||
vim.api.nvim_create_autocmd({"VimEnter"}, {
|
||||
callback = function()
|
||||
-- term:ctl at 4
|
||||
require('harpoon.term').gotoTerminal(4)
|
||||
vim.cmd([[:exe ":file term:ctl"]])
|
||||
-- term:dev at 5
|
||||
require('harpoon.term').gotoTerminal(5)
|
||||
vim.cmd([[:exe ":file term:dev"]])
|
||||
-- term:repl at 7
|
||||
require('harpoon.term').gotoTerminal(7)
|
||||
vim.cmd([[:exe ":file term:repl"]])
|
||||
-- term:repl at 6
|
||||
require('harpoon.term').gotoTerminal(6)
|
||||
vim.cmd([[:exe ":file term:repl2"]])
|
||||
end
|
||||
})
|
||||
|
||||
|
||||
vim.cmd([[
|
||||
set ignorecase
|
||||
set smartcase
|
||||
|
@ -130,8 +149,8 @@ vim.g.maplocalleader = ','
|
|||
|
||||
-- basic keymaps
|
||||
vim.keymap.set({ 'n', 'v' }, '<Space>', '<Nop>', { silent = true }) -- since we're using space for leader
|
||||
vim.keymap.set('t', '<Esc>', '<C-\\><C-n>)') -- make :terminal escape out
|
||||
vim.keymap.set({ 'n', 'i', 'v' }, '<c-l>', '<Cmd>:mode<Cr>') -- redraw on every mode
|
||||
vim.keymap.set('t', '<C-Esc>', '<C-\\><C-n>)') -- make :term escape out with ctrl-esc
|
||||
vim.keymap.set({ 'n', 'i', 'v' }, '<c-l>', 'Redraw neovim') -- redraw on every mode
|
||||
|
||||
-- diagnostics (errors/warnings to be shown)
|
||||
vim.keymap.set('n', '[d', vim.diagnostic.goto_prev)
|
||||
|
|
|
@ -81,7 +81,19 @@ in
|
|||
};
|
||||
oh-my-zsh = {
|
||||
enable = true;
|
||||
plugins = [ "git" "sudo" "command-not-found" "gitignore" "ripgrep" "rust" ];
|
||||
plugins = [
|
||||
"git" # git command aliases: https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/git#aliases
|
||||
"sudo" # double-escape to prepend sudo
|
||||
"command-not-found" # suggests which package to install; does not support nixos (we have solution already)
|
||||
"gitignore" # `gi list` -> `gi java >>.gitignore`
|
||||
"ripgrep" # adds completion for `rg`
|
||||
"rust" # compe for rustc/cargo
|
||||
"vi-mode" # edit promps with vi motions :)
|
||||
];
|
||||
};
|
||||
sessionVariables = {
|
||||
VI_MODE_RESET_PROMPT_ON_MODE_CHANGE = true;
|
||||
VI_MODE_SET_CURSOR = true;
|
||||
};
|
||||
initExtra = cfg.shellInitExtra or "";
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue