dotfiles

:)
git clone https://git.sr.ht/~ashymad/dotfiles
Log | Files | Refs | Submodules | LICENSE

commit 984287c3bc239c87c04407a0fa1caa8dade7b093
parent abb76708062c75c723dd1c476c1bade970c49543
Author: Ashymad <czilukim@o2.pl>
Date:   Wed, 16 May 2018 10:32:03 +0200

Merge branch 'master' into notwobug

Diffstat:
Mcmus/.cmus/cmus-geeqie.sh | 12++++--------
Mfish/.config/fish/functions/aur-async.fish | 4++--
Mnvim/.config/nvim/init.vim | 30++++++++++++++++++++++++------
Mpolybar/.config/polybar/cmus.sh | 22++++++++++------------
4 files changed, 40 insertions(+), 28 deletions(-)

diff --git a/cmus/.cmus/cmus-geeqie.sh b/cmus/.cmus/cmus-geeqie.sh @@ -4,13 +4,14 @@ ## There are several album art viewers for Cmus but this I believe is the most ## compatible with different setups as it is simpler. No weird hacks. -## Requires feh (light no-gui image viewer). +STATUS=$( cmus-remote -Q | tee /tmp/cmus.status) + +FOLDER=$( echo "$STATUS" | grep "file" | sed "s/file //" | rev | cut -d"/" -f2- | rev ) -FOLDER=$( cmus-remote -Q | grep "file" | sed "s/file //" | rev | \ -cut -d"/" -f2- | rev ) if [[ ${FOLDER:0:3} == "cue" ]]; then FOLDER=$(echo "$FOLDER" | sed 's/cue:\/\///g' | rev | cut -d"/" -f2- | rev) fi + FLIST=$( find "$FOLDER" -type f ) if echo "$FLIST" | grep -i ".jpeg\|.png\|.jpg" &>/dev/null; then @@ -21,12 +22,7 @@ if echo "$FLIST" | grep -i ".jpeg\|.png\|.jpg" &>/dev/null; then ART=$( echo "$FLIST" | grep -i ".png\|.jpg\|.jpeg" | head -n1 ) fi - - - # '200x200' is the window size for the artwork. '+1160+546' is the offset. - # For example, if you want a 250 by 250 window on the bottom right hand corner of a 1920 by 1080 screen: "250x250+1670+830" geeqie -r File:"$ART" else geeqie -r File:"/home/shyman/.cmus/none.jpg" - exit fi diff --git a/fish/.config/fish/functions/aur-async.fish b/fish/.config/fish/functions/aur-async.fish @@ -1,5 +1,5 @@ function aur-async - aur sync --repo=custom-aur -f --no-ver $argv - sudo pacman -S $argv[1] + aur sync -f --no-ver $argv + and sudo pacman -S $argv end diff --git a/nvim/.config/nvim/init.vim b/nvim/.config/nvim/init.vim @@ -48,8 +48,14 @@ Plug 'Shougo/neosnippet-snippets' " Git Plug 'tpope/vim-fugitive' +" Camel/Snake case movement +Plug 'bkad/CamelCaseMotion' + call plug#end() +" Enable CamelCaseMotion +call camelcasemotion#CreateMotionMappings('<leader>') + " Deoplete let g:deoplete#enable_at_startup = 1 inoremap <expr><C-h> deoplete#smart_close_popup()."\<C-h>" @@ -60,6 +66,22 @@ set completeopt+=noinsert let g:neosnippet#enable_completed_snippet = 1 +"Use 24-bit (true-color) mode in Vim/Neovim when outside tmux. +"If you're using tmux version 2.2 or later, you can remove the outermost $TMUX check and use tmux's 24-bit color support +"(see < http://sunaku.github.io/tmux-24bit-color.html#usage > for more information.) +if (empty($TMUX)) + if (has("nvim")) + "For Neovim 0.1.3 and 0.1.4 < https://github.com/neovim/neovim/pull/2198 > + let $NVIM_TUI_ENABLE_TRUE_COLOR=1 + endif + "For Neovim > 0.1.5 and Vim > patch 7.4.1799 < https://github.com/vim/vim/commit/61be73bb0f965a895bfb064ea3e55476ac175162 > + "Based on Vim patch 7.4.1770 (`guicolors` option) < https://github.com/vim/vim/commit/8a633e3427b47286869aa4b96f2bfc1fe65b25cd > + " < https://github.com/neovim/neovim/wiki/Following-HEAD#20160511 > + if (has("termguicolors")) + set termguicolors + endif +endif + " Disable latexBox in polyglot let g:polyglot_disabled = ['latex'] @@ -98,12 +120,6 @@ let g:deoplete#omni#input_patterns.tex = g:vimtex#re#deoplete map <C-l> :NERDTreeToggle<CR> -" let g:ycm_python_binary_path = 'python' -" -" if !exists('g:ycm_semantic_triggers') -" let g:ycm_semantic_triggers = {} -" endif -" let g:ycm_semantic_triggers.tex = g:vimtex#re#youcompleteme set hidden let g:LanguageClient_serverCommands = { @@ -116,6 +132,8 @@ nnoremap <silent> K :call LanguageClient#textDocument_hover()<CR> nnoremap <silent> gd :call LanguageClient#textDocument_definition()<CR> nnoremap <silent> <F2> :call LanguageClient#textDocument_rename()<CR> +let R_latexcmd = ['latexmk','-pdf','-pdflatex="xelatex -synctex=1 -interaction=nonstopmode"'] + syntax on colorscheme onedark set noshowmode diff --git a/polybar/.config/polybar/cmus.sh b/polybar/.config/polybar/cmus.sh @@ -1,14 +1,12 @@ #!/bin/sh -if cmus-remote -C status > /tmp/cmus.status; then - - TITLE=$(grep 'tag title ' /tmp/cmus.status | tail -c +11) - ARTIST=$(grep 'tag artist ' /tmp/cmus.status | tail -c +12) - STATE=$(grep 'status ' /tmp/cmus.status | tail -c +8) - if [ $STATE = 'playing' ]; then - echo "▶ $ARTIST - $TITLE" - elif [ $STATE = 'paused' ]; then - echo "⏸ $ARTIST - $TITLE" - else - echo "■" - fi +TITLE=$(grep 'tag title ' /tmp/cmus.status | tail -c +11) +ARTIST=$(grep 'tag artist ' /tmp/cmus.status | tail -c +12) +STATE=$(grep 'status ' /tmp/cmus.status | tail -c +8) + +if [ $STATE = 'playing' ]; then + echo "▶ $ARTIST - $TITLE" +elif [ $STATE = 'paused' ]; then + echo "⏸ $ARTIST - $TITLE" +else + echo "■" fi