zsh hist
This commit is contained in:
parent
bee2daacc1
commit
15fbe4c8f6
@ -216,6 +216,7 @@ autocmd BufRead *.py set smartindent cinwords=if,elif,else,for,while,try,except,
|
||||
" run file by filetype
|
||||
autocmd BufEnter * if (&filetype=='python') | nnoremap <silent> <Leader>r :tabnew % <CR> :terminal python3 % <CR> :set nocursorline number norelativenumber <CR> G <CR> | endif
|
||||
autocmd BufEnter * if (&filetype=='go') | nnoremap <silent> <Leader>r :tabnew % <CR> :terminal go run % <CR> :set nocursorline number norelativenumber <CR> G <CR> | endif
|
||||
autocmd BufEnter * if (&filetype=='markdown') | nnoremap <silent> <Leader>r :tabnew % <CR> :terminal glow % <CR> :set nocursorline number norelativenumber <CR> G <CR> | endif
|
||||
autocmd BufEnter * if (&filetype=='vim') | nnoremap <silent> <Leader>r :so % <CR>
|
||||
|
||||
|
||||
|
||||
@ -3,11 +3,14 @@
|
||||
export HISTFILE=~/.zsh_history
|
||||
export HISTSIZE=1000
|
||||
export SAVEHIST=2000
|
||||
setopt HIST_IGNORE_SPACE
|
||||
setopt hist_expire_dups_first # delete duplicates first when HISTFILE size exceeds HISTSIZE
|
||||
setopt hist_ignore_dups # ignore duplicated commands history list
|
||||
setopt hist_ignore_space # ignore commands that start with space
|
||||
setopt hist_verify # show command with history expansion to user before running it
|
||||
#setopt share_history # share command history data
|
||||
|
||||
HISTORY_IGNORE="(exit|q|c)"
|
||||
|
||||
# configure `time` format
|
||||
TIMEFMT=$'\nreal\t%E\nuser\t%U\nsys\t%S\ncpu\t%P'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user