diff options
-rw-r--r-- | .tmux.conf | 17 | ||||
-rw-r--r-- | .zshrc | 6 | ||||
-rw-r--r-- | baseline/.vimrc | 1 | ||||
-rw-r--r-- | init.vim | 493 | ||||
-rw-r--r-- | irssi/solarized-powerline.theme | 12 | ||||
-rw-r--r-- | makefilecpp | 4 | ||||
-rwxr-xr-x | tmux/date.sh | 2 | ||||
-rw-r--r-- | torrc | 3 |
8 files changed, 332 insertions, 206 deletions
@@ -7,14 +7,23 @@ set -g @plugin 'tmux-plugins/tmux-copycat' set -g @plugin 'schasse/tmux-jump' set -g @plugin 'tmux-plugins/tmux-yank' set -g @plugin 'wfxr/tmux-fzf-url' -set -g @continuum-restore 'on' set -g @plugin 'tmux-plugins/tmux-prefix-highlight' set -g @plugin 'tmux-plugins/tmux-continuum' + +set -g @continuum-restore 'on' +set -g @continuum-save-interval '15' +set -g @keyboard_layout:length 2 +# set -g @keyboard_layout:option_scope '-' + # set -g @plugin 'tmux-plugins/tmux-sidebar' # set -g @resurrect-processes `ranger ssh w3mlastsession k9s top cointop newsboat irssi neomutt` set -g @fzf-url-history-limit '2000' set -g @fzf-url-fzf-options '-w 50% -h 50% --multi -0 --no-preview --no-border' +# set -g automatic-rename on +# set -g renumber-windows on +# set -g- set-titles on + set-window-option -g automatic-rename on set-option -g set-titles on set -g focus-events on @@ -145,10 +154,8 @@ set-option -g status-left-length 120 set-option -g status-right-length 170 continuumStatus="#[fg=colour16 bg=colour70]#{continuum_status}#{?#{pane_ssh_connected},#[fg=colour70 bg=colour31],#[fg=colour70 bg=colour24]}" -# set-option -g status-left "#{prefix_highlight}$wg_is_keys_off#[fg=colour15 bg=colour22]#U@#H#[fg=colour22 bg=colour148]#(/home/devi/tmux-powerline/powerline.sh left)" -# set-option -g status-right "#(/home/devi/tmux-powerline/powerline.sh right)#{online_status}" -set-option -g status-left "#{prefix_highlight}$wg_is_keys_off$continuumStatus#{?#{pane_ssh_connected},#[fg=colour15 bold],#[fg=colour15 nobold]}#U@#H#{?#{pane_ssh_connected},:#{pane_ssh_port}#[fg=colour31 bg=colour26],#[fg=colour24 bg=colour26]}#[nobold]#(/home/devi/scripts/tmux/vcs_info.sh)" -# set-option -g status-left "#{prefix_highlight}$wg_is_keys_off#{?#{pane_ssh_connected},#[fg=colour15 bg=colour31],#[fg=colour15 bg=colour24]}#[fg=colour15 bg=colour31]#U@#H:#{pane_ssh_port}#[fg=colour31 bg=colour61]#(/home/devi/scripts/tmux/vcs_info.sh)" +sshStatus="#{?#{pane_ssh_connected},#[fg=colour15 bold],#[fg=colour15 nobold]}#U@#H#{?#{pane_ssh_connected},:#{pane_ssh_port}#[fg=colour31 bg=colour26],#[fg=colour24 bg=colour26]}" +set-option -g status-left "#{prefix_highlight}$wg_is_keys_off$continuumStatus$sshStatus#[nobold]#(/home/devi/scripts/tmux/vcs_info.sh)" set-option -g status-right "#(/home/devi/scripts/tmux/date.sh)#{online_status}" current_window_format="#{?window_zoomed_flag,#[fg=colour63#, bg=colour16]#[fg=colour63#, bg=colour16#, bold] Z #W #[fg=colour63#, bg=colour16],#[fg=colour255#, bg=colour16] #I #W #[fg=colour255#, bg=colour16]}" @@ -99,6 +99,7 @@ alias vps="ssh 87.236.209.206 -l ubuntu -p 1022" alias vpn="ssh 192.99.102.52 -l rooot -p 1022" alias vpn2="ssh 145.239.165.137 -l rooot" alias vpn3="ssh root@185.112.147.110 -p 2022" +alias vpn6="ssh -p 3022 ubuntu@2a07:e01:3:204::1" alias pytags="ctags --fields=+l --languages=python --python-kinds=-iv -R ." alias v="vim" alias kshrc="vim ~/scripts/.kshrc" @@ -161,6 +162,7 @@ alias socks5vpn1="autossh -M 0 -N -D 9999 -o ServerAliveInterval=180 -o ServerAl alias socks5vpn2="autossh -M 0 -N -D 9996 -o ServerAliveInterval=180 -o ServerAliveCountMax=3 -o ExitOnForwardFailure=yes -l rooot -p 1022 192.99.102.52" alias socks5vpn3="autossh -M 0 -N -D 9995 -o ServerAliveInterval=180 -o ServerAliveCountMax=3 -o ExitOnForwardFailure=yes -l root -p 2022 185.112.147.110" alias socks5vpn4="autossh -M 0 -N -D 9994 -o ServerAliveInterval=180 -o ServerAliveCountMax=3 -o ExitOnForwardFailure=yes -l ubuntu -p 1022 130.185.121.80" +alias socks5vpn6="autossh -M 0 -N -D 9993 -o ServerAliveInterval=180 -o ServerAliveCountMax=3 -o ExitOnForwardFailure=yes -6 -l ubuntu -p 3022 2a07:e01:3:204::1" alias cloud_one="ssh 130.185.121.80 -l ubuntu -p 1022" alias zharf_server="zssh 192.168.12.5 -l farzad" alias k9sskin="vim ~/scripts/.k9s/skin.yml" @@ -182,7 +184,7 @@ alias zh_linux="zssh dev@192.168.90.17" alias zh_router_root="zssh root@192.168.90.71" alias zh_router_admin="zssh admin@192.168.90.71" alias youtube_dl="proxychains4 -f /home/devi/proxies/ca/proxychains.conf youtube-dl" -alias campv="proxychains4 -f /home/devi/proxies/ca/proxychains.conf mpv" +alias campv="proxychains4 -f /home/devi/proxies/ca/proxychains.conf mpv --no-video" alias tridactylrc="vim ~/scripts/.tridactylrc" alias fixtridactylrc="cp ~/scripts/.tridactylrc ~/" alias man="man -O width=210" @@ -206,6 +208,8 @@ alias vm_disposable_alpine="cp ~/scripts/vagrant/disposable-alpine/Vagrantfile . alias checktor="curl --socks5 localhost:9050 --socks5-hostname localhost:9050 -s https://check.torproject.org/api/ip" alias ip="ip --color=auto" alias zathura="tabbed -c zathura -e" +alias ytfzf="proxychains4 -q -f ~/proxies/ice/proxychains.conf ytfzf" +alias newsboat="proxychains4 -q -f ~/proxies/ice/proxychains.conf newsboat" #autosuggest ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#5f5fff,bg=#000000,bold,underline" diff --git a/baseline/.vimrc b/baseline/.vimrc index e459f99..bbec499 100644 --- a/baseline/.vimrc +++ b/baseline/.vimrc @@ -29,7 +29,6 @@ filetype plugin indent on " jellybeans colo jellybeans set background=dark -let g:gruvbox_italics = 1 let g:jellybeans_overrides = { \ 'Todo': { 'guifg': '000000', 'guibg': '00cc00', \ 'ctermfg': 'Black', 'ctermbg': 'Blue', @@ -1,189 +1,304 @@ -
-let mapleader = " "
-call plug#begin('~/AppData/Local/nvim/plugged')
-Plug 'glacambre/firenvim', { 'do': { _ -> firenvim#install(0) } }
-Plug 'vim-airline/vim-airline'
-Plug 'vim-airline/vim-airline-themes'
-Plug 'rhysd/vim-gfm-syntax'
-Plug 'unblevable/quick-scope'
-Plug 'tpope/vim-commentary'
-Plug 'ctrlpvim/ctrlp.vim'
-Plug 'unblevable/quick-scope'
-Plug 'mbbill/undotree'
-Plug 'adelarsq/vim-matchit'
-Plug 'easymotion/vim-easymotion'
-Plug 'tpope/vim-surround'
-Plug 'tpope/vim-repeat'
-Plug 'nanotech/jellybeans.vim'
-Plug 'fatih/vim-go'
-Plug 'plasticboy/vim-markdown'
-Plug 'scrooloose/nerdtree'
-Plug 'ryanoasis/vim-devicons'
-Plug 'sheerun/vim-polyglot'
-call plug#end()
-
-set encoding=UTF-8
-set linebreak
-set breakindent
-let &showbreak = '↪ '
-set secure
-set list
-set wrap
-set showmatch
-set number
-set relativenumber
-set expandtab
-set noerrorbells
-set foldmethod=manual
-set nofoldenable
-set numberwidth=5
-set history=1000
-set tabstop=2
-set hidden
-set smarttab
-set autoindent
-set autoread
-set ttyfast
-set ignorecase smartcase
-set magic
-set lazyredraw
-set hlsearch
-set scrolloff=0
-set tagbsearch
-set wildmenu
-set noerrorbells
-set novisualbell
-
-let g:gfm_syntax_enable_always = 0
-let g:gfm_syntax_enable_filetypes = ['markdown.gfm']
-autocmd BufRead,BufNew,BufNewFile README.md setlocal ft=markdown.gfm
-
-function! OnUIEnter(event)
- let l:ui = nvim_get_chan_info(a:event.chan)
- if has_key(l:ui, 'client') && has_key(l:ui.client, 'name')
- if l:ui.client.name ==# 'Firenvim'
- set guifont=DejaVuSansMono\ NF:h12
- endif
- endif
-endfunction
-" autocmd QueInit UIEnter * call OnUIEnter(deepcopy(v:event))
-
-colo jellybeans
-let g:airline_powerline_fonts = 0
-try
- let g:airline#extensions#tabline#enabled = 1
- let g:airline#extensions#tabline#left_sep = ' '
- let g:airline#extensions#tabline#left_alt_sep = '|'
- let g:airline#extensions#tabline#formatter = 'default'
- let g:airline#extensions#ale#enabled = 1
- let g:airline#extensions#branch#enabled = 1
- " let g:airline#extensions#xkblayout#enabled = 1
-catch
-endtry
-let g:airline_theme = 'jellybeans'
-function! Airline_Custom()
- let l:spc = g:airline_symbols.space
- let g:airline_section_z = airline#section#create([
- \ 'windowswap',
- \ '%3p%%'.l:spc,
- \ 'linenr',
- \ ':%3v'.l:spc,
- \ '%5o',
- \ '[%b][0x%B]'
- \])
-endfunction
-autocmd user AirlineAfterInit call Airline_Custom()
-" let g:XkbSwitchLib = '/usr/local/lib/libxkbswitch.so'
-let g:airline_exclude_preview = 1
-
-"camel and snake case motion
-let g:camelchar = "A-Z0-9.,;:{([`'\"_"
-nnoremap <silent><C-h> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR>
-nnoremap <silent><C-l> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR>
-inoremap <silent><C-h> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR>
-inoremap <silent><C-l> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR>
-vnoremap <silent><C-h> :<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR>v`>o
-vnoremap <silent><C-l> <Esc>`>:<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR>v`<o
-
-nmap <Backspace> <Nop>
-nmap <Delete> <Nop>
-nmap <Left> <Nop>
-nmap <Down> <Nop>
-nmap <Up> <Nop>
-nmap <Right> <Nop>
-nmap <PageUp> <Nop>
-nmap <PageDown> <Nop>
-imap <PageUp> <Nop>
-imap <PageDown> <Nop>
-map <F3> :bp<CR>
-map <F4> :bn<CR>
-map <C-e> :q<cr>
-inoremap " ""<left>
-inoremap ' ''<left>
-inoremap ( ()<left>
-inoremap [ []<left>
-inoremap { {}<left>
-inoremap {<CR> {<CR>}<ESC>O
-map <leader>w :w<CR>
-nnoremap <F7> :NERDTreeToggle<CR>
-nnoremap <F12> :UndotreeToggle<CR>
-nnoremap <F10> :vsp<cr>
-nnoremap <S-F10> :sp<cr>
-nnoremap <leader>c :call clearmatches()<CR>
-nnoremap <leader>t :bel term<CR>
-nnoremap <leader>r :!%:p<CR>
-nnoremap <leader>cd :cd %:p:h<cr>
-
-let g:qs_highlight_on_keys = ["f", "F", "t", "T"]
-"
-"netrw
-let g:netrw_sort_by = 'date'
-let g:netrw_sort_direction = 'reverse'
-let g:netrw_banner = 0
-let g:netrw_liststyle = 3
-let g:netrw_browse_split = 1
-let g:netrw_winsize = 15
-let g:netrw_fastbrowse = 1
-let g:netrw_sort_by = 'name'
-let g:netrw_sort_direction = 'normal'
-
-"vim-go
-let g:go_auto_sameids = 1
-let g:go_highlight_functions = 1
-let g:go_highlight_function_calls = 1
-let g:go_highlight_types = 1
-let g:go_highlight_operators = 1
-let g:go_highlight_function_parameters = 1
-" let g:go_highlight_variable_declarations = 1
-" let g:go_highlight_variable_assignments = 1
-let g:go_doc_popup_window = 1
-let g:go_code_completion_enabled = 0
-
-"quickscope
-let g:qs_highlight_on_keys = ["f", "F", "t", "T"]
-
-" undotree
-set undolevels=1000
-if has("persistent_undo")
- set undodir=~/.undodir/
- set undofile
-endif
-let g:undotree_WindowLayout = 4
-
-iab strign string
-iab pritn print
-iab retrun return
-iab return return
-iab fucntion function
-iab funciton function
-iab tehn then
-iab coutn count
-iab accoutn account
-
-au BufEnter github.com_*.txt set filetype=markdown
-nnoremap <Esc><Esc> :call firenvim#focus_page()<CR>
-nnoremap <C-z> :call firenvim#hide_frame()<CR>
-
-"yaml
-autocmd FileType yaml setlocal ts=2 sts=2 sw=2 expandtab
-let g:indentLine_char = '|'
+ +let mapleader = " " +call plug#begin('~/AppData/Local/nvim/plugged') +Plug 'glacambre/firenvim', { 'do': { _ -> firenvim#install(0) } } +Plug 'vim-airline/vim-airline' +Plug 'vim-airline/vim-airline-themes' +Plug 'rhysd/vim-gfm-syntax' +Plug 'unblevable/quick-scope' +Plug 'tpope/vim-commentary' +Plug 'ctrlpvim/ctrlp.vim' +Plug 'unblevable/quick-scope' +Plug 'mbbill/undotree' +Plug 'adelarsq/vim-matchit' +Plug 'easymotion/vim-easymotion' +Plug 'tpope/vim-surround' +Plug 'tpope/vim-repeat' +Plug 'nanotech/jellybeans.vim' +Plug 'fatih/vim-go' +Plug 'plasticboy/vim-markdown' +Plug 'scrooloose/nerdtree' +Plug 'ryanoasis/vim-devicons' +Plug 'sheerun/vim-polyglot' +Plug 'lifepillar/vim-mucomplete' +call plug#end() + +set encoding=UTF-8 +set linebreak +set breakindent +let &showbreak = '↪ ' +set secure +set list +set wrap +set showmatch +set number +set relativenumber +set expandtab +set noerrorbells +set foldmethod=manual +set nofoldenable +set numberwidth=5 +set history=1000 +set tabstop=2 +set hidden +set smarttab +set autoindent +set autoread +set ttyfast +set ignorecase smartcase +set magic +set lazyredraw +set hlsearch +set scrolloff=0 +set tagbsearch +set wildmenu +set noerrorbells +set novisualbell + +" jellybeans +colo jellybeans +set background=dark +let g:jellybeans_overrides = { +\ 'Todo': { 'guifg': '000000', 'guibg': '00cc00', +\ 'ctermfg': 'Black', 'ctermbg': 'Blue', +\ 'attr': 'bold' }, +\ 'Comment': { 'guifg': '339966', 'guibg': '000000' }, +\ 'background': { "guibg": "000000", "ctermbg":"none"}, +\ 'StorageClass': {"guifg": '9966ff' }, +\ 'Exception': {"guifg": "99cc00"}, +\ "Ignore": {"guifg": "336699"}, +\ "SpecialComment": {"guifg": "009900"}, +\ "Macro": {"guifg": "0099cc"} +\} +let g:jellybeans_use_term_italics = 1 + +let g:gfm_syntax_enable_always = 0 +let g:gfm_syntax_enable_filetypes = ['markdown.gfm'] +autocmd BufRead,BufNew,BufNewFile README.md setlocal ft=markdown.gfm + +function! OnUIEnter(event) + let l:ui = nvim_get_chan_info(a:event.chan) + if has_key(l:ui, 'client') && has_key(l:ui.client, 'name') + if l:ui.client.name ==# 'Firenvim' + set guifont=DejaVuSansMono\ NF:h12 + endif + endif +endfunction +" autocmd QueInit UIEnter * call OnUIEnter(deepcopy(v:event)) + +colo jellybeans +let g:airline_powerline_fonts = 0 +try + let g:airline#extensions#tabline#enabled = 1 + let g:airline#extensions#tabline#left_sep = ' ' + let g:airline#extensions#tabline#left_alt_sep = '|' + let g:airline#extensions#tabline#formatter = 'default' + let g:airline#extensions#ale#enabled = 1 + let g:airline#extensions#branch#enabled = 1 + " let g:airline#extensions#xkblayout#enabled = 1 +catch +endtry +let g:airline_theme = 'jellybeans' +function! Airline_Custom() + let l:spc = g:airline_symbols.space + let g:airline_section_z = airline#section#create([ + \ 'windowswap', + \ '%3p%%'.l:spc, + \ 'linenr', + \ ':%3v'.l:spc, + \ '%5o', + \ '[%b][0x%B]' + \]) +endfunction +autocmd user AirlineAfterInit call Airline_Custom() +" let g:XkbSwitchLib = '/usr/local/lib/libxkbswitch.so' +let g:airline_exclude_preview = 1 + +"camel and snake case motion +let g:camelchar = "A-Z0-9.,;:{([`'\"_" +nnoremap <silent><C-h> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR> +nnoremap <silent><C-l> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR> +inoremap <silent><C-h> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR> +inoremap <silent><C-l> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR> +vnoremap <silent><C-h> :<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR>v`>o +vnoremap <silent><C-l> <Esc>`>:<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR>v`<o + +nmap <Backspace> <Nop> +nmap <Delete> <Nop> +nmap <Left> <Nop> +nmap <Down> <Nop> +nmap <Up> <Nop> +nmap <Right> <Nop> +nmap <PageUp> <Nop> +nmap <PageDown> <Nop> +imap <PageUp> <Nop> +imap <PageDown> <Nop> +map <F3> :bp<CR> +map <F4> :bn<CR> +map <C-e> :q<cr> +inoremap " ""<left> +inoremap ' ''<left> +inoremap ( ()<left> +inoremap [ []<left> +inoremap { {}<left> +inoremap {<CR> {<CR>}<ESC>O +map <leader>w :w<CR> +nnoremap <F7> :NERDTreeToggle<CR> +nnoremap <F12> :UndotreeToggle<CR> +nnoremap <F10> :vsp<cr> +nnoremap <S-F10> :sp<cr> +nnoremap <leader>c :call clearmatches()<CR> +nnoremap <leader>t :bel term<CR> +nnoremap <leader>r :!%:p<CR> +nnoremap <leader>cd :cd %:p:h<cr> +inoremap <c-a> <esc>I +inoremap <c-e> <esc>A +nnoremap <S-Delete> :bd<CR> +map <F6> <nop> +nnoremap <leader>c :call clearmatches()<CR> +map <leader>w :w<CR> +nnoremap <leader>t :bel term<CR> +nnoremap <leader>r :!%:p<CR> + +let g:qs_highlight_on_keys = ["f", "F", "t", "T"] +" +"netrw +let g:netrw_sort_by = 'date' +let g:netrw_sort_direction = 'reverse' +let g:netrw_banner = 0 +let g:netrw_liststyle = 3 +let g:netrw_browse_split = 1 +let g:netrw_winsize = 15 +let g:netrw_fastbrowse = 1 +let g:netrw_sort_by = 'name' +let g:netrw_sort_direction = 'normal' + +"vim-go +let g:go_auto_sameids = 1 +let g:go_highlight_functions = 1 +let g:go_highlight_function_calls = 1 +let g:go_highlight_types = 1 +let g:go_highlight_operators = 1 +let g:go_highlight_function_parameters = 1 +" let g:go_highlight_variable_declarations = 1 +" let g:go_highlight_variable_assignments = 1 +let g:go_doc_popup_window = 1 +let g:go_code_completion_enabled = 0 + +"quickscope +let g:qs_highlight_on_keys = ["f", "F", "t", "T"] + +" undotree +set undolevels=1000 +if has("persistent_undo") + set undodir=~/.undodir/ + set undofile +endif +let g:undotree_WindowLayout = 4 + +iab adn and +iab teh the +iab strign string +iab pritn print +iab retrun return +iab fucntion function +iab funciton function +iab tehn then +iab coutn count +iab accoutn account +iab applciation application +iab cosnt const +iab ehco echo + +au BufEnter github.com_*.txt set filetype=markdown +nnoremap <Esc><Esc> :call firenvim#focus_page()<CR> +nnoremap <C-z> :call firenvim#hide_frame()<CR> + +"yaml +autocmd FileType yaml setlocal ts=2 sts=2 sw=2 expandtab +let g:indentLine_char = '|' + +inoremap " ""<left> +inoremap ' ''<left> +inoremap ( ()<left> +inoremap [ []<left> +inoremap { {}<left> +inoremap {<CR> {<CR>}<ESC>O + +"camel and snake case motion +let g:camelchar = "A-Z0-9.,;:{([`'\"_" +nnoremap <silent><C-h> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR> +nnoremap <silent><C-l> :<C-u>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR> +inoremap <silent><C-h> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR> +inoremap <silent><C-l> <C-o>:call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR> +vnoremap <silent><C-h> :<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%^','bW')<CR>v`>o +vnoremap <silent><C-l> <Esc>`>:<C-U>call search('\C\<\<Bar>\%(^\<Bar>[^'.g:camelchar.']\@<=\)['.g:camelchar.']\<Bar>['.g:camelchar.']\ze\%([^'.g:camelchar.']\&\>\@!\)\<Bar>\%$','W')<CR>v`<o + +" highlight groups +hi def InterestingWord1 ctermfg=16 ctermbg=214 guifg=#000000 guibg=#ffaf00 +hi def InterestingWord2 ctermfg=16 ctermbg=154 guifg=#000000 guibg=#afff00 +hi def InterestingWord3 ctermfg=16 ctermbg=121 guifg=#000000 guibg=#87ffaf +hi def InterestingWord4 ctermfg=16 ctermbg=137 guifg=#000000 guibg=#af875f +hi def InterestingWord5 ctermfg=16 ctermbg=211 guifg=#000000 guibg=#ff87af +hi def InterestingWord6 ctermfg=16 ctermbg=195 guifg=#000000 guibg=#d7ffff +hi def InterestingWord7 ctermfg=16 ctermbg=99 guifg=#000000 guibg=#875fff +hi def InterestingWord8 ctermfg=16 ctermbg=35 guifg=#000000 guibg=#00af5f +hi def InterestingWord9 ctermfg=16 ctermbg=209 guifg=#000000 guibg=#ff875f +hi def InterestingWord0 ctermfg=16 ctermbg=39 guifg=#000000 guibg=#00afff + +" Steve Losh's highlight function +function HighInterestingWord(n) + normal! mz + normal! "zyiw + let mid = 88888 + a:n + silent! call matchdelete(mid) + let pat = '\V\<' . escape(@z, '\') . '\>' + call matchadd("InterestingWord".a:n, pat, 1, mid) + normal! `z +endfunction + +" multiple highlights +nnoremap <silent> <leader>1 :call HighInterestingWord(1)<cr> +nnoremap <silent> <leader>2 :call HighInterestingWord(2)<cr> +nnoremap <silent> <leader>3 :call HighInterestingWord(3)<cr> +nnoremap <silent> <leader>4 :call HighInterestingWord(4)<cr> +nnoremap <silent> <leader>5 :call HighInterestingWord(5)<cr> +nnoremap <silent> <leader>6 :call HighInterestingWord(6)<cr> +nnoremap <silent> <leader>7 :call HighInterestingWord(7)<cr> +nnoremap <silent> <leader>8 :call HighInterestingWord(8)<cr> +nnoremap <silent> <leader>9 :call HighInterestingWord(9)<cr> +nnoremap <silent> <leader>0 :call HighInterestingWord(0)<cr> + +"copy and paste between different Vim sessions +nmap _Y :!echo ""> ~/.vi_tmp<CR><CR>:w! ~/.vi_tmp<CR> +vmap _Y :w! ~/.vi_tmp<CR> +nmap _P :r ~/.vi_tmp<CR> + +"mucomplete +set completeopt+=menuone +let g:mucomplete#enable_auto_at_startup = 1 +let g:mucomplete#completion_delay = 1 + +" firenvim write changes automatically, throttle writes +let g:timer_started = v:false +function! My_Write(timer) abort + let g:timer_started = v:false + write +endfunction + +function! Delay_My_Write() abort + if g:timer_started + return + end + let g:timer_started = v:true + call timer_start(10000, 'My_Write') +endfunction + +au TextChanged * ++nested call Delay_My_Write() +au TextChangedI * ++nested call Delay_My_Write() + +let g:firenvim_config = { + \ 'globalSettings': { + \ 'cmdlineTimeout': 3000, + \ } +\ } diff --git a/irssi/solarized-powerline.theme b/irssi/solarized-powerline.theme index 734aefa..31744c3 100644 --- a/irssi/solarized-powerline.theme +++ b/irssi/solarized-powerline.theme @@ -232,7 +232,7 @@ abstracts = { ## # whois - whois = "%k%z005f87WHOIS %N%k%#%N $[8]0 %Y$1-"; + whois = "%k%z005f87WHOIS %0%Z005f87%N%#%N $[8]0 %Y$1-"; # notices ownnotice = "%z8787ff%k %k$0 %k%z8787ff%8%0 {ichannelhilight $1-} %k%z00af5f%N "; @@ -433,9 +433,9 @@ formats = { default_event_server = "%k%z00d700$0 %N%k %N%n$1"; ebanlist = "%p%z00d700BANS %k exception %8 {ichannelhilight $0} %N%8%n%k%N {ban $1}"; ebanlist_long = "%p%z00d700BANS %k exception %8 {ichannelhilight $0} {comment by {inick $2}%0%k, $3 secs ago} %N%8%n%k%N {ban $1}"; - end_of_who = "%z00d700%kWHO %N%k%N END"; - end_of_whois = "%z00d700%kWHOIS %N%k%N END"; - end_of_whowas = "%z00d700%kWHOWAS %N%k%N END"; + end_of_who = "%z00d700%kWHO %Z00d700%0%N END"; + end_of_whois = "%z00d700%kWHOIS %Z00d700%0%N END"; + end_of_whowas = "%z00d700%kWHOWAS %Z00d700%0%N END"; netsplit = "%k%z8787ff%8%8 NETSPLIT %0%w%0%8 {iserver $0} %z00d700%8 {iserver $1}%8 %N%8%n%k%N Quits: $2"; netsplit_join = "%k%z8787ff NETSPLIT %k%8%N Joins: $0"; netsplit_join_more = "%k%z8787ff NETSPLIT %k%8%N Joins: $0 (+$1 more)"; @@ -448,8 +448,8 @@ formats = { unaway = "%k%z00d700AWAY %N%k%N END"; usermode_change = "%z008700%ZeeeeeeMODE %N%Z008700%N {mode $0}%N for %0{mynick $1}%N"; who = "%z00d700%kWHO %z005f87%k {inick $[!9]1} %Z005f87 %k$0 %0%g Status: $[!3]2 $[-2]3 hops %N%k%N {nickhost $4@$5} {comment $6}"; - whois = "%z00d700%kWHOIS %N%k%n {nick $0} {nickhost $1@$2}%:{whois ircname $3}"; - whowas = "%z00d700%kWHOWAS %N%k%n {nick $0} {nickhost $1@$2}%:{whois was $3}"; + whois = "%z00d700%kWHOIS %Z00d700%0%n {nick $0} {nickhost $1@$2}%:{whois ircname $3}"; + whowas = "%z00d700%kWHOWAS %Z00d700%0%n {nick $0} {nickhost $1@$2}%:{whois was $3}"; own_action = "$nickalign{ownaction $0$nicktrunc}$1"; action_private = "$nickalign{pvtaction $0$nicktrunc}$2"; action_private_query = "$nickalign{pvtaction_query $0$nicktrunc}$2"; diff --git a/makefilecpp b/makefilecpp index e3c5892..d5e9dc0 100644 --- a/makefilecpp +++ b/makefilecpp @@ -4,9 +4,9 @@ SHELL?=bash CXX=clang++ CXX?=clang++ ifdef OS -CXX_FLAGS=-std=c++17 +CXX_FLAGS=-std=c++20 else -CXX_FLAGS=-std=c++17 -fpic +CXX_FLAGS=-std=c++20 -fpic endif CXX_EXTRA?= CTAGS_I_PATH?=./ diff --git a/tmux/date.sh b/tmux/date.sh index f8ce7c4..42044a4 100755 --- a/tmux/date.sh +++ b/tmux/date.sh @@ -11,7 +11,7 @@ DAY="#[fg=colour255 bg=colour31]"$(echo $RESULT | gawk '{print $1}') DATE="#[fg=colour255 bg=colour31]"$(echo $RESULT | gawk '{print $2}') TIME="#[fg=colour255 bg=colour31]"$(echo $RESULT | gawk '{print $3}') UTC_TIME_RESULT=$(date -u +"%H:%M") -UTC_TIME="#[fg=colour255 bg=colour25]"$(echo GMT: $UTC_TIME_RESULT) +UTC_TIME="#[fg=colour255 bg=colour25]"$(echo $UTC_TIME_RESULT) JDATE="#[fg=colour255 bg=colour29]"$(jdate | gawk '{print $2" "$3}') # OPENWEATHERMAP_TOKEN=$(cat /home/devi/scripts/tmux/openweathermap.json|jq -r ".token") # WEATHER_INFO=$(sleep 120 && torsocks curl "https://api.openweathermap.org/data/2.5/weather?q=Tehran&appid=$OPENWEATHERMAP_TOKEN&units=metric"|jq ".main.temp") @@ -22,8 +22,9 @@ ## Tor opens a SOCKS proxy on port 9050 by default -- even if you don't ## configure one below. Set "SOCKSPort 0" if you plan to run Tor only ## as a relay, and not make any local application connections yourself. -SOCKSPort [::1]:9050 # Default: Bind to localhost:9050 for local connections. +##SOCKSPort [::1]:9050 # Default: Bind to localhost:9050 for local connections. #SOCKSPort 192.168.0.1:9100 # Bind to this address:port too. +SOCKSPort 0 ## Entry policies to allow/deny SOCKS requests based on IP address. ## First entry that matches wins. If no SOCKSPolicy is set, we accept |