From 63a4c3122b04d347152d6949e1abd7ad75a12634 Mon Sep 17 00:00:00 2001 From: Daniel Flanagan Date: Wed, 25 Sep 2019 07:16:15 -0500 Subject: [PATCH 1/3] Add helpful scripts for timing stuff --- scripts/bin/countdown | 13 +++++++++++++ scripts/bin/sw | 11 +++++++++++ 2 files changed, 24 insertions(+) create mode 100755 scripts/bin/countdown create mode 100755 scripts/bin/sw diff --git a/scripts/bin/countdown b/scripts/bin/countdown new file mode 100755 index 0000000..aa88762 --- /dev/null +++ b/scripts/bin/countdown @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +d=$((`date +%s` + $1)); +echo "Countdown started $(date)" + +while [ "$d" -ge $(date +%s) ]; do + _dt=$(($d - `date +%s`)) + days=$((_dt / 86400)) + echo -ne "\r${days}d $(date -u --date @$((_dt)) +%H:%M:%S) "; + sleep 0.1 +done + +echo -ne "\rCountdown finished $(date)\n" diff --git a/scripts/bin/sw b/scripts/bin/sw new file mode 100755 index 0000000..58f1713 --- /dev/null +++ b/scripts/bin/sw @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +d="$(date +%s)" +echo "Stopwatch started $(date)" + +while true; do + _dt=$((`date +%s` - d)) + days=$((_dt / 86400)) + echo -ne "\r${days}d $(date -u --date @$((_dt)) +%H:%M:%S) " + sleep 0.1 +done From b245ba2117b0d49adbead125a9d036fc6768c0e3 Mon Sep 17 00:00:00 2001 From: Daniel Flanagan Date: Thu, 26 Sep 2019 12:04:23 -0500 Subject: [PATCH 2/3] Updates --- apps/neovim/bindings.vim | 25 ++++++++++++++----- apps/neovim/plugins.vim | 3 ++- apps/neovim/settings.vim | 11 +++++++- de/sxhkd/sxhkdrc | 8 ++++-- scripts/arch-linux/provisioning/3-extras.bash | 3 ++- scripts/bin/app-launcher | 2 +- 6 files changed, 40 insertions(+), 12 deletions(-) diff --git a/apps/neovim/bindings.vim b/apps/neovim/bindings.vim index 45f1027..1df73a1 100644 --- a/apps/neovim/bindings.vim +++ b/apps/neovim/bindings.vim @@ -118,11 +118,6 @@ nnoremap l :Buffers " switch to previous buffer nnoremap h :b# -" go to definitions -nnoremap gd :ALEGoToDefinition -nnoremap gh :ALEGoToDefinitionInSplit -nnoremap gv :ALEGoToDefinitionInVSplit - " use leader j and k to switch buffers as well nnoremap k :bnext nnoremap j :bprevious @@ -211,7 +206,25 @@ xnoremap < >gv " distraction-free mode -nnoremap df :DistractionFreeMode +nnoremap df :DistractionFreeMode " recalc syntax highlighting nnoremap gs :syntax sync fromstart + +" lsp bindings + +" coc + +" open coc config +nnoremap c :CocConfig + +" go to definitions +nnoremap d (coc-jump-definition) + +" ale + +" go to definitions +" nnoremap gd :ALEGoToDefinition +" nnoremap gh :ALEGoToDefinitionInSplit +" nnoremap gv :ALEGoToDefinitionInVSplit + diff --git a/apps/neovim/plugins.vim b/apps/neovim/plugins.vim index 98bc8a1..981e043 100644 --- a/apps/neovim/plugins.vim +++ b/apps/neovim/plugins.vim @@ -108,7 +108,8 @@ Plug 'sheerun/vim-polyglot' " vim plugin loa Plug 'leafo/moonscript-vim', {'for': ['moon', 'moonscript']} " moonscript language Plug 'OmniSharp/omnisharp-vim', {'for': ['cs']} " C# language Plug 'neoclide/coc.nvim', {'branch': 'release'} " language server completion -Plug 'JakeBecker/elixir-ls', {'for': ['elixir'], 'do': { -> g:elixirls.compile() }} +Plug 'neoclide/coc-json' " coc config ft +Plug 'JakeBecker/elixir-ls', {'for': ['elixir', 'eelixir'], 'do': { -> g:elixirls.compile() }} Plug 'tpope/vim-dadbod' " databasing in vim " Plug 'lytedev/elm-vim' " elm lang Plug 'ssh://git@git.lyte.dev:2222/lytedev/vim-lytlang.git' diff --git a/apps/neovim/settings.vim b/apps/neovim/settings.vim index 9b9b4b2..afe5d57 100644 --- a/apps/neovim/settings.vim +++ b/apps/neovim/settings.vim @@ -2,7 +2,6 @@ scriptencoding utf8 " ALE completeopt recommendation set completeopt=menu,menuone,preview,noselect,noinsert -" set completeopt=noinsert,menuone,noselect,longest,preview " line number defaults set nonumber @@ -156,3 +155,13 @@ highlight CursorLineNr ctermbg=18 ctermfg=gray hi IndentGuidesEven ctermbg=18 hi Normal ctermbg=NONE + +" lsp config + +" ale + +" set completeopt=noinsert,menuone,noselect,longest,preview + +" coc + + diff --git a/de/sxhkd/sxhkdrc b/de/sxhkd/sxhkdrc index 0259802..e933c38 100755 --- a/de/sxhkd/sxhkdrc +++ b/de/sxhkd/sxhkdrc @@ -140,10 +140,14 @@ super + alt + minus super + r bspc node -R 90 -# balance the current node +# balance the current node's leaves super + shift + b bspc node -B +# balance the current node's sibling leaves +super + ctrl + b + bspc node -f parent && bspc node -B + # wm-independant shortcuts # spawn a transparent node @@ -252,7 +256,7 @@ super + d xdotool key super+4 && sleep 0.1 && xdotool key shift+4 && xdotool key shift+4 && xdotool key shift+4 && sleep 0.2 && xdotool key super+1 && xdotool key super+3 super + ctrl + c - bspc rule -a '*' -o state=floating && urxvtc --geometry 80x16 -e sh -c "khal calendar && bash" + bspc rule -a '*' -o state=floating && urxvtc --geometry 64x9 -e sh -c "cal -n 3 && bash" super + shift + v kill -USR1 $(cat "/var/run/user/$UID/polybar-mic-script.pid") diff --git a/scripts/arch-linux/provisioning/3-extras.bash b/scripts/arch-linux/provisioning/3-extras.bash index 6cc66b3..70b1688 100755 --- a/scripts/arch-linux/provisioning/3-extras.bash +++ b/scripts/arch-linux/provisioning/3-extras.bash @@ -21,7 +21,7 @@ pacaur --needed -S \ audacity `# Audio Editing Application` \ cmake `# Cross-Platform Make` \ accountsservice `# Mainly for User Avatars with LightDM` \ - deluge `# GUI Torrent Client` \ + deluge cairo python-cairo `# GUI Torrent Client` \ lightdm lightdm-gtk-greeter `# Nice User Login` \ polybar-git `# Bar` \ php `# PHP Language` \ @@ -40,4 +40,5 @@ pacaur --needed -S \ gnome-shell `# Guh-nome Guh-shell` \ redshift `# Save Your Eyes` \ vlc `# Video Viewer` \ + ncdu `# Disk Usage Analyzer` \ --noconfirm --noedit diff --git a/scripts/bin/app-launcher b/scripts/bin/app-launcher index 532e015..e626c5e 100755 --- a/scripts/bin/app-launcher +++ b/scripts/bin/app-launcher @@ -2,7 +2,7 @@ source "$DOTFILES_PATH/de/bar/bar.bash" --just-vars -LAUNCHER_FONT=$(xrdb -query | sed -ne 's/.*font:\s*xft:\([^:]*\).*$/\1/p' | head -n 1) +LAUNCHER_FONT=$(xrdb -query | sed -ne 's/.*font:\s*xft:\([^: ]*\).*$/\1/p' | head -n 1) LAUNCHER_FONT_SIZE=$(xrdb -query | sed -ne 's/.*font:\s*xft:.*=\([0-9]*\).*$/\1/p' | head -n 1) HIGHLIGHT_COLOR=$(xrdb -query | sed -ne 's/.*color4*:\s*\(.*\)$/\1/p' | head -n 1) HIGHLIGHT_FOREGROUND_COLOR=$(xrdb -query | sed -ne 's/.*background:\s*\(.*\)$/\1/p' | head -n 1) From af2e9294d114ee518beab1cbd4476577e968d321 Mon Sep 17 00:00:00 2001 From: Daniel Flanagan Date: Thu, 26 Sep 2019 12:08:50 -0500 Subject: [PATCH 3/3] Comments are nice --- scripts/arch-linux/provisioning/2-essentials.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/arch-linux/provisioning/2-essentials.bash b/scripts/arch-linux/provisioning/2-essentials.bash index 9556d19..6351f90 100755 --- a/scripts/arch-linux/provisioning/2-essentials.bash +++ b/scripts/arch-linux/provisioning/2-essentials.bash @@ -44,7 +44,7 @@ pacaur --needed -S \ jq `# CLI for Interacting with JSON` \ ranger `# CLI File Manager` \ bash-completion `# Handy Scripts for Tab-Completion in Bash` \ - python-neovim python-jedi python-mistune python-psutil python-setproctitle httpie \ + python-neovim python-jedi python-mistune python-psutil python-setproctitle httpie `# httpie and neovim dependencies` \ --noconfirm --noedit # install rxvt-unicode script for resizing font on-the-fly