diff --git a/i3/config b/i3/config new file mode 120000 index 0000000..25e1107 --- /dev/null +++ b/i3/config @@ -0,0 +1 @@ +config-laptoparbeit \ No newline at end of file diff --git a/i3/config-laptoparbeit b/i3/config-laptoparbeit index b44089e..d3ae117 100644 --- a/i3/config-laptoparbeit +++ b/i3/config-laptoparbeit @@ -12,17 +12,17 @@ set $mod Mod4 # Workspace assignment for monitors -workspace "z:s" output eDP-1 -workspace "u:s" output eDP-1 -workspace "i:s" output eDP-1 -workspace "o:s" output eDP-1 +workspace "z:s" output eDP +workspace "u:s" output eDP +workspace "i:s" output eDP +workspace "o:s" output eDP #-- -workspace "1:l" output DP-2-2 -workspace "2:l" output DP-2-2 -workspace "3:l" output DP-2-2 -workspace "4:l" output DP-2-2 -workspace "5:l" output DP-2-2 -workspace "6:l" output DP-2-2 +workspace "1:l" output HDMI-A-0 +workspace "2:l" output HDMI-A-0 +workspace "3:l" output HDMI-A-0 +workspace "4:l" output HDMI-A-0 +workspace "5:l" output HDMI-A-0 +workspace "6:l" output HDMI-A-0 #-- dockingstation # workspace "7:r" output DP-2-1 # workspace "8:r" output DP-2-1 @@ -30,11 +30,11 @@ workspace "6:l" output DP-2-2 # workspace "0:r" output DP-2-1 # workspace "ß:r" output DP-2-1 #-- hdmi out -workspace "7:r" output HDMI-2 -workspace "8:r" output HDMI-2 -workspace "9:r" output HDMI-2 -workspace "0:r" output HDMI-2 -workspace "ß:r" output HDMI-2 +workspace "7:r" output HDMI-A-0 +workspace "8:r" output HDMI-A-0 +workspace "9:r" output HDMI-A-0 +workspace "0:r" output HDMI-A-0 +workspace "ß:r" output HDMI-A-0 # Font for window titles. Will also be used by the bar unless a different font @@ -177,6 +177,7 @@ bindsym $mod+F4 exec sh ~/config/susp.sh #bindsym $mod+y exec xfce4-terminal --drop-down exec_always --no-startup-id /home/dario/.local/bin/kitti3 -n bubblegum -p top bindsym $mod+y nop bubblegum +#bindsym $mod+y exec /home/dario/config/i3/scripts/i3quake -p top -H 0.4 kitty #for_window [class="(?i)xfce4-terminal"] floating enable #for_window [class="(?i)xfce4-terminal"] border none diff --git a/i3/scripts/i3quake b/i3/scripts/i3quake new file mode 100755 index 0000000..1cd9606 Binary files /dev/null and b/i3/scripts/i3quake differ diff --git a/nvim/autoload/plug.vim b/nvim/autoload/plug.vim index 9c296ac..6a958cb 100644 --- a/nvim/autoload/plug.vim +++ b/nvim/autoload/plug.vim @@ -116,6 +116,10 @@ let s:TYPE = { let s:loaded = get(s:, 'loaded', {}) let s:triggers = get(s:, 'triggers', {}) +function! s:is_powershell(shell) + return a:shell =~# 'powershell\(\.exe\)\?$' || a:shell =~# 'pwsh\(\.exe\)\?$' +endfunction + function! s:isabsolute(dir) abort return a:dir =~# '^/' || (has('win32') && a:dir =~? '^\%(\\\|[A-Z]:\)') endfunction @@ -263,7 +267,7 @@ function! s:define_commands() endif if has('win32') \ && &shellslash - \ && (&shell =~# 'cmd\(\.exe\)\?$' || &shell =~# 'powershell\(\.exe\)\?$') + \ && (&shell =~# 'cmd\(\.exe\)\?$' || s:is_powershell(&shell)) return s:err('vim-plug does not support shell, ' . &shell . ', when shellslash is set.') endif if !has('nvim') @@ -503,7 +507,7 @@ if s:is_win let batchfile = s:plug_tempname().'.bat' call writefile(s:wrap_cmds(a:cmd), batchfile) let cmd = plug#shellescape(batchfile, {'shell': &shell, 'script': 0}) - if &shell =~# 'powershell\(\.exe\)\?$' + if s:is_powershell(&shell) let cmd = '& ' . cmd endif return [batchfile, cmd] @@ -935,7 +939,7 @@ function! s:prepare(...) call s:new_window() endif - nnoremap q :if b:plug_preview==1pcendifbd + nnoremap q :call close_pane() if a:0 == 0 call s:finish_bindings() endif @@ -957,6 +961,15 @@ function! s:prepare(...) endif endfunction +function! s:close_pane() + if b:plug_preview == 1 + pc + let b:plug_preview = -1 + else + bd + endif +endfunction + function! s:assign_name() " Assign buffer name let prefix = '[Plugins]' @@ -975,7 +988,7 @@ function! s:chsh(swap) set shell=sh endif if a:swap - if &shell =~# 'powershell\(\.exe\)\?$' || &shell =~# 'pwsh$' + if s:is_powershell(&shell) let &shellredir = '2>&1 | Out-File -Encoding UTF8 %s' elseif &shell =~# 'sh' || &shell =~# 'cmd\(\.exe\)\?$' set shellredir=>%s\ 2>&1 @@ -2216,7 +2229,7 @@ function! plug#shellescape(arg, ...) let script = get(opts, 'script', 1) if shell =~# 'cmd\(\.exe\)\?$' return s:shellesc_cmd(a:arg, script) - elseif shell =~# 'powershell\(\.exe\)\?$' || shell =~# 'pwsh$' + elseif s:is_powershell(shell) return s:shellesc_ps1(a:arg) endif return s:shellesc_sh(a:arg) @@ -2268,7 +2281,7 @@ function! s:system(cmd, ...) return system(a:cmd) endif let cmd = join(map(copy(a:cmd), 'plug#shellescape(v:val, {"shell": &shell, "script": 0})')) - if &shell =~# 'powershell\(\.exe\)\?$' + if s:is_powershell(&shell) let cmd = '& ' . cmd endif else diff --git a/nvim/coc-settings.json b/nvim/coc-settings.json index 7a8f257..54b44e6 100644 --- a/nvim/coc-settings.json +++ b/nvim/coc-settings.json @@ -6,8 +6,11 @@ //"python.jediEnabled": false, //"python.analysis.memory.keepLibraryAst": true, //"python.analysis.memory.keepLibraryLocalVariables": true, - "python.formatting.provider": "black", //"coc.preferences.formatOnSaveFiletypes": ["python"], + "python.formatting.provider": "black", "python.linting.pylintEnabled": true, + "python.analysis.diagnosticMode": "workspace", + "python.linting.mypyEnabled": true, + "python.analysis.typeCheckingMode": "off" //"suggest.timeout": 15000 } diff --git a/nvim/conf.d/coc.vim b/nvim/conf.d/coc.vim index f65210a..39230b9 100644 --- a/nvim/conf.d/coc.vim +++ b/nvim/conf.d/coc.vim @@ -28,8 +28,8 @@ nmap ti (coc-implementation) nmap tr (coc-references) nmap te (coc-diagnostic-next-error) nmap tn (coc-diagnostic-next) -xmap ,r (coc-format-selected) -nmap ,r (coc-format-selected) +xmap ,r (coc-format) +nmap ,r (coc-format) " Add `:Format` command to format current buffer. command! -nargs=0 Format :call CocAction('format') diff --git a/ocrscrot b/ocrscrot new file mode 100755 index 0000000..ebc0c8a --- /dev/null +++ b/ocrscrot @@ -0,0 +1,9 @@ +#!/bin/bash + +TEMPF=$(mktemp ocrscrot.XXXXXXX) +rm $TEMPF + +scrot -s $TEMPF.png +tesseract -l deu+eng $TEMPF.png - | xsel + +rm $TEMPF.png diff --git a/zsh/.zshrc b/zsh/.zshrc index c688f28..b0422fa 100644 --- a/zsh/.zshrc +++ b/zsh/.zshrc @@ -363,7 +363,7 @@ zrcautoload is-at-least || function is-at-least () { return 1 } setopt append_history # import new commands from the history file also in other zsh-session -is4 && setopt share_history +# is4 && setopt share_history # save each command's beginning timestamp and the duration to the history file setopt extended_history diff --git a/zsh/.zshrc.local b/zsh/.zshrc.local index 15dd785..080e3a0 100644 --- a/zsh/.zshrc.local +++ b/zsh/.zshrc.local @@ -1,12 +1,14 @@ # fuzzy finder source /usr/share/doc/fzf/examples/key-bindings.zsh +source /usr/share/doc/fzf/examples/completion.zsh + bindkey '^H' fzf-cd-widget time source /usr/share/virtualenvwrapper/virtualenvwrapper.sh alias preview="fzf --preview 'bat --color \"always\" {}'" alias rg="rg -S -p" alias ldict="dict.cc.py en de" -alias cat='batcat' +alias bat='batcat' alias unp='dtrx' alias clearr="printf '\033[2J\033[3J\033[1;1H'" @@ -43,3 +45,5 @@ export PYENV_ROOT="$HOME/source/pyenv" export PATH="$PYENV_ROOT/bin:$PATH" export PATH=/usr/lib/cargo/bin/:$PATH:/home/dario/.local/bin/ + +export BAT_THEME="ansi-dark"