Improved terminal keybindings
parent
e71e7f1c48
commit
6eda27510a
|
@ -80,11 +80,15 @@ inoremap <Esc> <nop>
|
||||||
nnoremap <leader>a <C-^>
|
nnoremap <leader>a <C-^>
|
||||||
|
|
||||||
" Terminal keybindings
|
" Terminal keybindings
|
||||||
|
" I use the terminal inside Neovim a lot, so I have some keybindings to easily
|
||||||
|
" open one
|
||||||
" Use jk in terminal as well
|
" Use jk in terminal as well
|
||||||
tnoremap <silent> jk <C-\><C-n>
|
tnoremap <silent> jk <C-\><C-n>
|
||||||
" Open terminal in different locations
|
|
||||||
nnoremap <silent> <leader>rr :terminal<CR>
|
" I explicitely use $SHELL, because my main shell is not necessarily Bash, and
|
||||||
nnoremap <silent> <leader>rh :vsp<CR>:wincmd h<CR>:term<CR>
|
" I want to use my main shell inside Vim as well
|
||||||
nnoremap <silent> <leader>rl :vsp<CR>:term<CR>
|
nnoremap <silent> <leader>rr :e term://$SHELL<CR>
|
||||||
nnoremap <silent> <leader>rk :sp<CR>:wincmd k<CR>:term<CR>
|
nnoremap <silent> <leader>rh :vsp<CR>:wincmd h<CR>:e term://$SHELL<CR>
|
||||||
nnoremap <silent> <leader>rj :sp<CR>:term<CR>
|
nnoremap <silent> <leader>rl :vsp<CR>:e term://$SHELL<CR>
|
||||||
|
nnoremap <silent> <leader>rk :sp<CR>:wincmd k<CR>:e term://$SHELL<CR>
|
||||||
|
nnoremap <silent> <leader>rj :sp<CR>:e term://$SHELL<CR>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
" Listing of paths to ignore. I think I could use something similar to CtrlP
|
" Listing of paths to ignore. I think I could use something similar to CtrlP
|
||||||
" here as well, but I want NERDTree to also show some non-version
|
" here as well, but I want NERDTree to also show some non-version
|
||||||
" controlled files
|
" controlled files. It ignores the following files:
|
||||||
" Vim
|
" Vim
|
||||||
" Other IDEs
|
" Other IDEs
|
||||||
" Python
|
" Python
|
||||||
|
@ -12,8 +12,9 @@
|
||||||
let NERDTreeIgnore = [
|
let NERDTreeIgnore = [
|
||||||
\ '^\.vim$[[dir]]',
|
\ '^\.vim$[[dir]]',
|
||||||
\ '^\.vscode$[[dir]]', '.*\.code-workspace$[[file]]', '^\.idea$[[dir]]',
|
\ '^\.vscode$[[dir]]', '.*\.code-workspace$[[file]]', '^\.idea$[[dir]]',
|
||||||
\ '^__pycache__$[[dir]]', '^\.pytest_cache$[[dir]]', '^venv$[[dir]]', '\.egg-info$[[dir]]', '^dist$[[dir]]',
|
\ '^__pycache__$[[dir]]', '^\.pytest_cache$[[dir]]', '^venv$[[dir]]',
|
||||||
\ '^build$[[dir]]', '^\.eggs$[[dir]]',
|
\ '\.egg-info$[[dir]]', '^dist$[[dir]]', '^build$[[dir]]',
|
||||||
|
\ '^\.eggs$[[dir]]',
|
||||||
\ '^out$[[dir]]',
|
\ '^out$[[dir]]',
|
||||||
\ '^\.git$[[dir]]',
|
\ '^\.git$[[dir]]',
|
||||||
\ '^\.stack-work$[[dir]]', '\.lock$',
|
\ '^\.stack-work$[[dir]]', '\.lock$',
|
||||||
|
|
|
@ -1,3 +1,9 @@
|
||||||
|
" Terminal
|
||||||
|
" As I often use non-standard shells, certain things can break if this isn't
|
||||||
|
" explicitely set
|
||||||
|
" TODO maybe use which to find the executable?
|
||||||
|
set shell=/bin/bash
|
||||||
|
|
||||||
" Colorscheme
|
" Colorscheme
|
||||||
" This forces (Neo)Vim to assume the terminal supports 256 colors.
|
" This forces (Neo)Vim to assume the terminal supports 256 colors.
|
||||||
" Without this, some colorschemes (including mine) don't work properly.
|
" Without this, some colorschemes (including mine) don't work properly.
|
||||||
|
|
Reference in New Issue