@@ -148,6 +148,11 @@ alias music="ncmpcpp" | |||||
alias py='ipython3 --TerminalInteractiveShell.editing_mode=vi' | alias py='ipython3 --TerminalInteractiveShell.editing_mode=vi' | ||||
alias g='git' | alias g='git' | ||||
alias gc='git clone' | alias gc='git clone' | ||||
alias gs='git status' | |||||
alias ga='git add' | |||||
alias gb='git branch' | |||||
alias gl='git log' | |||||
alias gd='git diff' | |||||
# Edit config and system files | # Edit config and system files | ||||
alias edit-bashrc='vim $HOME/.bashrc' | alias edit-bashrc='vim $HOME/.bashrc' | ||||
@@ -288,7 +293,7 @@ export GOPATH="$HOME/go" | |||||
export GO111MODULE=on | export GO111MODULE=on | ||||
export EDITOR='vim' | export EDITOR='vim' | ||||
export PAGER='less' | export PAGER='less' | ||||
export NNN_BMS='h:~/;c:~/.config;n:~/Notes;' | |||||
export NNN_BMS='h:~/;c:~/.config;n:~/Notes;m:/mnt/media' | |||||
export NNN_FIFO=/tmp/nnn.fifo | export NNN_FIFO=/tmp/nnn.fifo | ||||
export NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | export NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | ||||
export USE_PISTOL=0 | export USE_PISTOL=0 | ||||
@@ -26,12 +26,12 @@ if [ -d "$HOME/.local/bin" ] ; then | |||||
PATH="$HOME/.local/bin:$PATH" | PATH="$HOME/.local/bin:$PATH" | ||||
fi | fi | ||||
export PATH="$HOME/.config/composer/vendor/bin:$HOME/go/bin:/usr/lib/go/bin:$PATH" | |||||
export PATH="/snap/bin:$HOME/.config/composer/vendor/bin:$HOME/go/bin:/usr/lib/go/bin:$PATH" | |||||
export GOPATH="$HOME/go" | export GOPATH="$HOME/go" | ||||
export GO111MODULE=on | export GO111MODULE=on | ||||
export EDITOR='vim' | export EDITOR='vim' | ||||
export PAGER='less' | export PAGER='less' | ||||
export NNN_BMS='h:~/;c:~/.config;n:~/Notes;' | |||||
export NNN_BMS='h:~/;c:~/.config;n:~/Notes;m:/mnt/media' | |||||
export NNN_FIFO=/tmp/nnn.fifo | export NNN_FIFO=/tmp/nnn.fifo | ||||
export NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | export NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | ||||
export USE_PISTOL=0 | export USE_PISTOL=0 | ||||
@@ -8,7 +8,13 @@ speaker_medium=🔉 | |||||
speaker_high=🔊 | speaker_high=🔊 | ||||
brightness_symbol=🔅 | brightness_symbol=🔅 | ||||
DELAY=1m | |||||
# Check number of unread emails | |||||
messages() { | |||||
printf "$(find ~/Mail -path '*INBOX*' -not -name \ | |||||
'.uidvalidity' -type f | grep -vE ',[^,]*S[^,]*$'| wc -l)" | |||||
} | |||||
DELAY=10m | |||||
while true; do | while true; do | ||||
mbsync -a | mbsync -a | ||||
@@ -28,7 +34,7 @@ while true; do | |||||
volume_symbol=$speaker_high | volume_symbol=$speaker_high | ||||
fi | fi | ||||
xsetroot -name "📧Messages $(find ~/Mail -path '*/INBOX/new' -type f | wc -l) | | |||||
xsetroot -name "📧Messages $(messages) | | |||||
$volume_symbol$volume | $(date +"%c")" | $volume_symbol$volume | $(date +"%c")" | ||||
sleep $DELAY | sleep $DELAY | ||||
done & | done & | ||||
@@ -49,7 +49,7 @@ set sort_re | |||||
# Mailboxes to show in the sidebar. | # Mailboxes to show in the sidebar. | ||||
# mailboxes =ALL-INBOX | # mailboxes =ALL-INBOX | ||||
mailboxes =personal/INBOX =personal/archive =personal/sent =personal/drafts =personal/junk =personal/trash | mailboxes =personal/INBOX =personal/archive =personal/sent =personal/drafts =personal/junk =personal/trash | ||||
mailboxes =work/INBOX | |||||
mailboxes =work/INBOX =work/Drafts =work/'Sent Items' =work/Calendar | |||||
# mailboxes =work/"[Gmail]INBOX" =work/"[Gmail]/Spam" =work/"[Gmail]/Trash" =work/"[Gmail]/All Mail" =work/Reference | # mailboxes =work/"[Gmail]INBOX" =work/"[Gmail]/Spam" =work/"[Gmail]/Trash" =work/"[Gmail]/All Mail" =work/Reference | ||||
# mailboxes =hussar | # mailboxes =hussar | ||||
# mailboxes =hussar/archive =hussar/sent =hussar/drafts =hussar/junk =hussar/trash | # mailboxes =hussar/archive =hussar/sent =hussar/drafts =hussar/junk =hussar/trash | ||||
@@ -22,7 +22,7 @@ set tgc "More terminal colours | |||||
let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum" | let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum" | ||||
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum" | let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum" | ||||
let base16colorspace=256 | let base16colorspace=256 | ||||
colorscheme base16-tomorrow-night | |||||
colorscheme base16-mocha | |||||
"Pymode stuff | "Pymode stuff | ||||
let g:pymode_folding = 0 | let g:pymode_folding = 0 | ||||
@@ -50,7 +50,6 @@ nmap <leader>L :CtrlPLine<cr> | |||||
"NERDTree bingings | "NERDTree bingings | ||||
nnoremap <F1> :NERDTreeToggle<cr> | nnoremap <F1> :NERDTreeToggle<cr> | ||||
nnoremap <leader>t :NERDTreeFind<cr> | nnoremap <leader>t :NERDTreeFind<cr> | ||||
nnoremap <F2> :NERDTreeFocus<cr> | |||||
"autocmd vimenter * NERDTree | "autocmd vimenter * NERDTree | ||||
@@ -71,13 +70,11 @@ nnoremap <F4> :tabnext<cr> | |||||
nnoremap <F5> :buffers<CR>:buffer<Space> | nnoremap <F5> :buffers<CR>:buffer<Space> | ||||
noremap <BS> <PageUp> | noremap <BS> <PageUp> | ||||
noremap <Space> <PageDown> | noremap <Space> <PageDown> | ||||
nmap <leader>p <C-w><C-r> | |||||
noremap <leader>y <C-W>w | |||||
noremap <C-h> <C-W>h | noremap <C-h> <C-W>h | ||||
noremap <C-l> <C-W>l | noremap <C-l> <C-W>l | ||||
noremap <C-j> <C-W>j | noremap <C-j> <C-W>j | ||||
noremap <C-k> <C-W>k | noremap <C-k> <C-W>k | ||||
nnoremap <leader>z :wa<cr> | |||||
nnoremap <leader>z :w<cr> | |||||
nnoremap <leader>c :CtrlPChange<cr> | nnoremap <leader>c :CtrlPChange<cr> | ||||
nnoremap <leader>C :CtrlPChangeAll<cr> | nnoremap <leader>C :CtrlPChangeAll<cr> | ||||
nnoremap <leader><cr> :center<cr> | nnoremap <leader><cr> :center<cr> | ||||
@@ -97,6 +94,8 @@ map <leader>ow <Plug>(easymotion-overwin-w) | |||||
nmap <leader>of <Plug>(easymotion-overwin-f2) | nmap <leader>of <Plug>(easymotion-overwin-f2) | ||||
nmap <leader>aw <Plug>(easymotion-bd-w) | nmap <leader>aw <Plug>(easymotion-bd-w) | ||||
nmap <leader>al <Plug>(easymotion-bd-jk) | nmap <leader>al <Plug>(easymotion-bd-jk) | ||||
let g:EasyMotion_smartcase = 1 " Infer search casing | |||||
let g:EasyMotion_startofline = 0 " keep cursor column when JK motion | |||||
"Copy and pasting | "Copy and pasting | ||||
vmap <C-c> "+y | vmap <C-c> "+y | ||||
@@ -217,3 +216,11 @@ let g:nnn#action = { | |||||
let $NNN_BMS='h:~/;c:~/.config;n:~/Notes;' | let $NNN_BMS='h:~/;c:~/.config;n:~/Notes;' | ||||
let $NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | let $NNN_PLUG='p:preview-tui;c:x2sel;i:imgview;s:tmspawn' | ||||
"let $NNN_FIFO=/tmp/nnn.fifo | "let $NNN_FIFO=/tmp/nnn.fifo | ||||
" Prettier settings | |||||
" let g:prettier#config#config_precedence = 'file-override' | |||||
let g:prettier#autoformat = 1 | |||||
let g:prettier#autoformat_require_pragma = 0 | |||||
let g:prettier#config#tab_width = 4 | |||||
" let g:prettier#config#use_tabs = 'false' |