diff options
author | Yigit Sever | 2020-01-04 16:21:34 +0300 |
---|---|---|
committer | Yigit Sever | 2020-01-04 16:21:34 +0300 |
commit | ec041431da07ece93a258674191ee8b16befcca6 (patch) | |
tree | a9a1de2111f3aef153c84cb0cdd161b3f8530218 | |
parent | 3cd07e80c97a6c9f9a7283b384da52d681824ec3 (diff) | |
parent | b7382c651d7246c1e0f17c42434ee30dd72ec017 (diff) | |
download | dotfiles-ec041431da07ece93a258674191ee8b16befcca6.tar.gz dotfiles-ec041431da07ece93a258674191ee8b16befcca6.tar.bz2 dotfiles-ec041431da07ece93a258674191ee8b16befcca6.zip |
Merge branch 'master' of 207.154.210.186:/home/yigit/dots
-rwxr-xr-x | .config/dunst/dunstrc | 4 | ||||
-rw-r--r-- | .config/i3/config##c.desktop,h.Lowe | 8 | ||||
-rwxr-xr-x | .config/nvim/init.vim | 96 | ||||
-rwxr-xr-x | .config/polybar/focus | 12 | ||||
-rw-r--r-- | .ssh/config | 1 | ||||
-rw-r--r-- | .taskrc##c.desktop,h.Lowe | 4 | ||||
-rwxr-xr-x | bin/spliff | 6 | ||||
-rwxr-xr-x | bin/watch_incoming.sh | 16 |
8 files changed, 94 insertions, 53 deletions
diff --git a/.config/dunst/dunstrc b/.config/dunst/dunstrc index e1d2052..523d3ba 100755 --- a/.config/dunst/dunstrc +++ b/.config/dunst/dunstrc | |||
@@ -57,3 +57,7 @@ timeout = 0 | |||
57 | [Spotify] | 57 | [Spotify] |
58 | appname = Spotify | 58 | appname = Spotify |
59 | format = "<b>Now Playing</b>\n%s\n%b" | 59 | format = "<b>Now Playing</b>\n%s\n%b" |
60 | |||
61 | [spliff] | ||
62 | appname = "spliff" | ||
63 | format = "<b>ready for printing</b>\n%s\n%b" | ||
diff --git a/.config/i3/config##c.desktop,h.Lowe b/.config/i3/config##c.desktop,h.Lowe index 30692e1..2e5a8c4 100644 --- a/.config/i3/config##c.desktop,h.Lowe +++ b/.config/i3/config##c.desktop,h.Lowe | |||
@@ -8,6 +8,9 @@ set $alt Mod1 | |||
8 | # launch polybar | 8 | # launch polybar |
9 | exec --no-startup-id $HOME/.config/polybar/launch.sh & | 9 | exec --no-startup-id $HOME/.config/polybar/launch.sh & |
10 | 10 | ||
11 | # launch spliffer + notification | ||
12 | exec --no-startup-id $HOME/bin/watch_incoming.sh | ||
13 | |||
11 | # start the screensaver, '' at the end is not a typo | 14 | # start the screensaver, '' at the end is not a typo |
12 | exec --no-startup-id xidlehook --not-when-fullscreen --not-when-audio --timer normal 300 'betterlockscreen -l dimblur -t "Welcome Back"' '' | 15 | exec --no-startup-id xidlehook --not-when-fullscreen --not-when-audio --timer normal 300 'betterlockscreen -l dimblur -t "Welcome Back"' '' |
13 | 16 | ||
@@ -105,11 +108,14 @@ bindsym $mod+e layout toggle split | |||
105 | # toggle tiling / floating | 108 | # toggle tiling / floating |
106 | bindsym $mod+Shift+space floating toggle | 109 | bindsym $mod+Shift+space floating toggle |
107 | 110 | ||
111 | # toggle sticky floating window | ||
112 | bindsym $mod+a sticky toggle | ||
113 | |||
108 | # change focus between tiling / floating windows | 114 | # change focus between tiling / floating windows |
109 | bindsym $mod+space focus mode_toggle | 115 | bindsym $mod+space focus mode_toggle |
110 | 116 | ||
111 | # focus the parent container | 117 | # focus the parent container |
112 | bindsym $mod+a focus parent | 118 | # bindsym $mod+a focus parent |
113 | 119 | ||
114 | # Define names for default workspaces for which we configure key bindings later on. | 120 | # Define names for default workspaces for which we configure key bindings later on. |
115 | # We use variables to avoid repeating the names in multiple places. | 121 | # We use variables to avoid repeating the names in multiple places. |
diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index fab8f58..9d52e0c 100755 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim | |||
@@ -1,100 +1,102 @@ | |||
1 | "{{{ Plugs | 1 | "{{{ Plugs |
2 | call plug#begin('~/.local/share/nvim/plugged') | 2 | call plug#begin('~/.local/share/nvim/plugged') |
3 | 3 | ||
4 | "completion | 4 | " completion |
5 | Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } | 5 | Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } |
6 | Plug 'lionawurscht/deoplete-biblatex' | 6 | Plug 'lionawurscht/deoplete-biblatex' |
7 | Plug 'deoplete-plugins/deoplete-jedi' | 7 | Plug 'deoplete-plugins/deoplete-jedi' |
8 | 8 | ||
9 | " ledger | 9 | " ledger |
10 | Plug 'ledger/vim-ledger' | 10 | Plug 'ledger/vim-ledger' |
11 | "language packs | 11 | " language packs |
12 | Plug 'sheerun/vim-polyglot' | 12 | Plug 'sheerun/vim-polyglot' |
13 | "syntax checking | 13 | " syntax checking |
14 | Plug 'dense-analysis/ale' | 14 | Plug 'dense-analysis/ale' |
15 | "manages tag files | 15 | " manages tag files |
16 | Plug 'ludovicchabant/vim-gutentags' | 16 | Plug 'ludovicchabant/vim-gutentags' |
17 | "run your tests | 17 | " run your tests |
18 | Plug 'janko/vim-test' | 18 | " Plug 'janko/vim-test' " TODO benched for now but should be useful later |
19 | " latex | 19 | " open a floating terminal |
20 | Plug 'lervag/vimtex' | 20 | Plug 'voldikss/vim-floaterm' |
21 | 21 | ||
22 | "snippet solution | 22 | " snippets to expand |
23 | Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' | 23 | Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' |
24 | "autopair plugin | 24 | " autopair plugin |
25 | Plug 'tmsvg/pear-tree' | 25 | Plug 'tmsvg/pear-tree' |
26 | "colored brackets | ||
27 | Plug 'luochen1990/rainbow' | ||
28 | 26 | ||
29 | " Plugin outside ~/.vim/plugged with post-update hook | 27 | " Plugin outside ~/.vim/plugged with post-update hook |
30 | Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } | 28 | Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } |
31 | Plug 'junegunn/fzf.vim' | 29 | Plug 'junegunn/fzf.vim' |
32 | 30 | ||
33 | "tree explorer | 31 | " tree explorer |
34 | Plug 'scrooloose/nerdtree' | 32 | " Plug 'scrooloose/nerdtree' TODO benched for now, use netrw |
35 | "displays tags ordered by scope | 33 | " displays tags ordered by scope |
36 | Plug 'majutsushi/tagbar' | 34 | Plug 'majutsushi/tagbar' |
37 | "status/tabline | 35 | " status/tabline |
38 | Plug 'bling/vim-airline' | 36 | Plug 'bling/vim-airline' |
37 | " floating terminal | ||
38 | Plug 'voldikss/vim-floaterm' | ||
39 | 39 | ||
40 | " " color theme | 40 | " color theme of $CURRENT_YEAR |
41 | Plug 'joshdick/onedark.vim' | 41 | Plug 'joshdick/onedark.vim' |
42 | 42 | ||
43 | "Personal wiki | 43 | " Personal wiki |
44 | Plug 'vimwiki/vimwiki' | 44 | Plug 'vimwiki/vimwiki' |
45 | "distraction-free writing | 45 | " centers the writing |
46 | Plug 'junegunn/goyo.vim' | 46 | Plug 'junegunn/goyo.vim' |
47 | " highlights the current parapraph | ||
47 | Plug 'junegunn/limelight.vim' | 48 | Plug 'junegunn/limelight.vim' |
49 | " latex | ||
50 | Plug 'lervag/vimtex' | ||
48 | 51 | ||
49 | "text alignment | 52 | " text alignment |
50 | Plug 'godlygeek/tabular' | 53 | Plug 'godlygeek/tabular' |
51 | "color code highlight | 54 | " color code highlight |
52 | Plug 'chrisbra/Colorizer' | 55 | " Plug 'chrisbra/Colorizer' " TODO benched for now, can't remember the last |
53 | "move selections up and down | 56 | " time this was useful |
57 | " move selections up and down | ||
54 | Plug 'matze/vim-move' | 58 | Plug 'matze/vim-move' |
55 | " search/select/edit sandwiched textobjects (vim-surround) | 59 | " search/select/edit sandwiched textobjects |
56 | Plug 'machakann/vim-sandwich' | 60 | Plug 'machakann/vim-sandwich' |
57 | " provide additional text objects | 61 | " provide additional text objects |
58 | Plug 'wellle/targets.vim' | 62 | Plug 'wellle/targets.vim' |
59 | " indentation level text object | 63 | " indentation level text object |
60 | Plug 'michaeljsmith/vim-indent-object' | 64 | Plug 'michaeljsmith/vim-indent-object' |
61 | " undo history visualizer | ||
62 | Plug 'mbbill/undotree' | ||
63 | 65 | ||
64 | "reopen files at your last edit position | 66 | " reopen files at your last edit position |
65 | Plug 'farmergreg/vim-lastplace' | 67 | Plug 'farmergreg/vim-lastplace' |
66 | "toggle, display and navigate marks | 68 | " toggle, display and navigate marks |
67 | Plug 'kshenoy/vim-signature' | 69 | " Plug 'kshenoy/vim-signature' TODO benched for now, never used |
68 | "git diff in the sign column | 70 | " git diff in the sign column |
69 | Plug 'airblade/vim-gitgutter' | 71 | Plug 'airblade/vim-gitgutter' |
70 | "jump to location by 2 characters | 72 | " jump to location by 2 characters |
71 | Plug 'justinmk/vim-sneak' | 73 | Plug 'justinmk/vim-sneak' |
72 | 74 | ||
73 | "splits delete into cut and delete | 75 | " splits delete into cut and delete |
74 | Plug 'svermeulen/vim-cutlass' | 76 | Plug 'svermeulen/vim-cutlass' |
75 | "change text with yank | 77 | " change text with yank |
76 | Plug 'svermeulen/vim-subversive' | 78 | Plug 'svermeulen/vim-subversive' |
77 | "yank history | 79 | " yank history |
78 | Plug 'svermeulen/vim-yoink' | 80 | Plug 'svermeulen/vim-yoink' |
79 | 81 | ||
80 | "enable repeating supported plugin maps with '.' | 82 | " enable repeating supported plugin maps with '.' |
81 | Plug 'tpope/vim-repeat' | 83 | Plug 'tpope/vim-repeat' |
82 | "pairs of handy bracket mappings | 84 | " pairs of handy bracket mappings |
83 | Plug 'tpope/vim-unimpaired' | 85 | Plug 'tpope/vim-unimpaired' |
84 | "git wrapper | 86 | " git wrapper |
85 | Plug 'tpope/vim-fugitive' | 87 | Plug 'tpope/vim-fugitive' |
86 | "increment dates, times & more | 88 | " increment dates, times & more |
87 | Plug 'tpope/vim-speeddating' | 89 | Plug 'tpope/vim-speeddating' |
88 | "search, substitute and abbreviate | 90 | " search, substitute and abbreviate |
89 | Plug 'tpope/vim-abolish' | 91 | Plug 'tpope/vim-abolish' |
90 | "provides ga, show unicode stuff of char under cursor | 92 | " provides ga, show unicode stuff of char under cursor |
91 | Plug 'tpope/vim-characterize' | 93 | Plug 'tpope/vim-characterize' |
92 | "comment helper | 94 | " comment helper |
93 | Plug 'tpope/vim-commentary' | 95 | Plug 'tpope/vim-commentary' |
94 | "asynchronous build and test dispatcher | 96 | " asynchronous build and test dispatcher |
95 | Plug 'tpope/vim-dispatch' | 97 | Plug 'tpope/vim-dispatch' |
96 | 98 | ||
97 | "fancy start screen | 99 | " fancy start screen |
98 | Plug 'mhinz/vim-startify' | 100 | Plug 'mhinz/vim-startify' |
99 | Plug 'ryanoasis/vim-devicons' " asks to be placed last, sure | 101 | Plug 'ryanoasis/vim-devicons' " asks to be placed last, sure |
100 | 102 | ||
@@ -112,6 +114,9 @@ autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isT | |||
112 | " Resize all windows proportionally when the terminal is resized | 114 | " Resize all windows proportionally when the terminal is resized |
113 | " let terminal resize scale the internal windows | 115 | " let terminal resize scale the internal windows |
114 | autocmd VimResized * :wincmd = | 116 | autocmd VimResized * :wincmd = |
117 | |||
118 | " Set spell for prose | ||
119 | autocmd FileType markdown,tex setlocal spell | ||
115 | "}}} | 120 | "}}} |
116 | 121 | ||
117 | "{{{Misc Settings | 122 | "{{{Misc Settings |
@@ -152,6 +157,8 @@ set splitbelow " new split panes will split to below and right | |||
152 | set splitright | 157 | set splitright |
153 | set cursorline | 158 | set cursorline |
154 | 159 | ||
160 | set thesaurus+=~/.local/share/thesaurus.txt | ||
161 | |||
155 | " persistent undo | 162 | " persistent undo |
156 | set undodir=~/.vim/undodir | 163 | set undodir=~/.vim/undodir |
157 | set undofile | 164 | set undofile |
@@ -185,7 +192,8 @@ colorscheme onedark | |||
185 | " Open the TagBar Plugin <F3> | 192 | " Open the TagBar Plugin <F3> |
186 | nnoremap <silent> <F3> :TagbarToggle<CR> | 193 | nnoremap <silent> <F3> :TagbarToggle<CR> |
187 | " Open NERDTree <F4> | 194 | " Open NERDTree <F4> |
188 | nnoremap <silent> <F4> :NERDTreeToggle<CR> | 195 | " nnoremap <silent> <F4> :NERDTreeToggle<CR> |
196 | let g:floaterm_keymap_toggle = '<F4>' | ||
189 | " Fix whole buffer via ALE | 197 | " Fix whole buffer via ALE |
190 | nmap <F9> <Plug>(ale_fix) | 198 | nmap <F9> <Plug>(ale_fix) |
191 | 199 | ||
diff --git a/.config/polybar/focus b/.config/polybar/focus index 8eeb92a..17c9862 100755 --- a/.config/polybar/focus +++ b/.config/polybar/focus | |||
@@ -34,10 +34,10 @@ $active_task_maybe =~ s/^\s+|\s+$//g; | |||
34 | my @lines = split /\n/, $active_task_maybe; | 34 | my @lines = split /\n/, $active_task_maybe; |
35 | 35 | ||
36 | my $task = $lines[2]; | 36 | my $task = $lines[2]; |
37 | $task =~ s/^\s+|\s+$//g; | 37 | $task =~ s/^\s+|\s+$//g; # left and right trim |
38 | $task =~ s/\s+/ /g; | 38 | $task =~ s/\s+/ /g; # reduce multiple whitespace into one |
39 | 39 | ||
40 | # if ($task =~ m/.*?next (.*)$/) { | 40 | if ($task =~ m/^(.*)?\s(\d+\w+)$/g) { |
41 | # print "$1"; | 41 | print "$1 | $2"; |
42 | # } | 42 | } |
43 | print $task; | 43 | # print $task; |
diff --git a/.ssh/config b/.ssh/config index bce878a..2930dbb 100644 --- a/.ssh/config +++ b/.ssh/config | |||
@@ -12,6 +12,7 @@ Host overseer | |||
12 | HostName 207.154.210.186 | 12 | HostName 207.154.210.186 |
13 | Port 22 | 13 | Port 22 |
14 | User yigit | 14 | User yigit |
15 | ServerAliveInterval 180 | ||
15 | Host dev | 16 | Host dev |
16 | HostName 10.10.3.49 | 17 | HostName 10.10.3.49 |
17 | Port 22 | 18 | Port 22 |
diff --git a/.taskrc##c.desktop,h.Lowe b/.taskrc##c.desktop,h.Lowe index b79820e..c8419c4 100644 --- a/.taskrc##c.desktop,h.Lowe +++ b/.taskrc##c.desktop,h.Lowe | |||
@@ -62,8 +62,8 @@ report.todoConky.filter = status:pending and due.after:now and due.before:l | |||
62 | report.todoConky.dateformat = D-M-y H:N (A) | 62 | report.todoConky.dateformat = D-M-y H:N (A) |
63 | 63 | ||
64 | ### report for focus script | 64 | ### report for focus script |
65 | report.custom_focus.columns = description | 65 | report.custom_focus.columns = description,start.age |
66 | report.custom_focus.labels = Description | 66 | report.custom_focus.labels = Description,active |
67 | report.custom_focus.description = Task to feed to focus script | 67 | report.custom_focus.description = Task to feed to focus script |
68 | report.custom_focus.filter = status:pending and +ACTIVE | 68 | report.custom_focus.filter = status:pending and +ACTIVE |
69 | 69 | ||
diff --git a/bin/spliff b/bin/spliff new file mode 100755 index 0000000..3767bac --- /dev/null +++ b/bin/spliff | |||
@@ -0,0 +1,6 @@ | |||
1 | #!/usr/bin/env zsh | ||
2 | |||
3 | PDF=$1 | ||
4 | OUTPUT="${PDF:r}_spliff.pdf" | ||
5 | N=`qpdf --show-npages $1` | ||
6 | qpdf --collate --empty --pages $1 1-$(((N+1)/2)) $1 $(((N+1)/2 + 1))-$N -- $OUTPUT | ||
diff --git a/bin/watch_incoming.sh b/bin/watch_incoming.sh new file mode 100755 index 0000000..eed1da0 --- /dev/null +++ b/bin/watch_incoming.sh | |||
@@ -0,0 +1,16 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | |||
3 | TARGET=$HOME/Downloads/toPrint/toPrint_staging | ||
4 | PROCESSED=$HOME/Downloads/toPrint/toPrint_ready | ||
5 | SPLIFF=$HOME/bin/spliff | ||
6 | |||
7 | inotifywait -m -e create -e moved_to --format "%f" "${TARGET}" \ | ||
8 | | while read -r FILENAME | ||
9 | do | ||
10 | THUMB=$(mktemp /tmp/pdf_thumbnail_XXXXXXXXX.png) | ||
11 | evince-thumbnailer -s 1024 -l "${TARGET}/${FILENAME}" "${THUMB}" | ||
12 | mv "${TARGET}/${FILENAME}" "${PROCESSED}/${FILENAME}" | ||
13 | $SPLIFF "${PROCESSED}/${FILENAME}" | ||
14 | rm -f "${PROCESSED}/${FILENAME}" | ||
15 | dunstify -a "spliff" -I "${THUMB}" "$FILENAME" | ||
16 | done | ||