Added timer bash function, added vim-rsi for readline shortcuts, added movement keys in insert mode to vim
This commit is contained in:
10
bash/.bashrc
10
bash/.bashrc
@@ -113,6 +113,16 @@ stopwatch () {
|
||||
date1=`date +%s`; while true; do echo -ne "$(date -u --date @$((`date +%s` - $date1)) +%H:%M:%S)\r"; done
|
||||
}
|
||||
|
||||
timer() {
|
||||
start="$(( $(date '+%s') + $1))"
|
||||
while [ $start -ge $(date +%s) ]; do
|
||||
time="$(( $start - $(date +%s) ))"
|
||||
printf '%s\r' "$(date -u -d "@$time" +%H:%M:%S)"
|
||||
sleep 0.1
|
||||
done
|
||||
notify-send "Timer Finished" "Timer Finished - $1 seconds elapsed"
|
||||
}
|
||||
|
||||
n ()
|
||||
{
|
||||
# Block nesting of nnn in subshells
|
||||
|
||||
11
vim/.vimrc
11
vim/.vimrc
@@ -34,6 +34,16 @@ set textwidth=79
|
||||
set shiftwidth=4
|
||||
set fileformat=unix
|
||||
|
||||
" move in insert mode
|
||||
inoremap <C-h> <Left>
|
||||
inoremap <C-j> <Down>
|
||||
inoremap <C-k> <Up>
|
||||
inoremap <C-l> <Right>
|
||||
cnoremap <C-h> <Left>
|
||||
cnoremap <C-j> <Down>
|
||||
cnoremap <C-k> <Up>
|
||||
cnoremap <C-l> <Right>
|
||||
|
||||
"highlight cursorline cterm=none ctermbg=darkred ctermfg=white guibg=darkred guifg=white
|
||||
hi cursorline cterm=none term=none ctermbg=236
|
||||
set cursorline
|
||||
@@ -123,6 +133,7 @@ Plug 'junegunn/goyo.vim'
|
||||
Plug 'junegunn/fzf.vim'
|
||||
Plug 'scrooloose/nerdtree'
|
||||
Plug 'chrisbra/Colorizer'
|
||||
Plug 'tpope/vim-rsi'
|
||||
" Colors
|
||||
Plug 'arzg/vim-substrata'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user