From 75db457f80e09ece1be32be21bc3b2890ea43ab7 Mon Sep 17 00:00:00 2001 From: DeadGit Date: Wed, 19 Aug 2020 14:30:47 -0300 Subject: [PATCH] limpieza --- .config/alacritty.yml | 6 +- .config/git/config | 114 ++++++++++++++++++--------------- .config/nvim/coc-settings.json | 16 +++++ .config/nvim/init.vim | 67 +++++++++---------- .config/sxhkd/sxhkdrc | 4 +- .config/tmux/tmux.conf | 2 +- .config/zsh/.zshrc | 15 ----- .config/zsh/aliases.zsh | 11 +--- .local/bin/powermenu | 2 +- .xinitrc | 1 + .zshenv | 9 +-- doc/xbpaketes | 27 ++------ 12 files changed, 123 insertions(+), 151 deletions(-) diff --git a/.config/alacritty.yml b/.config/alacritty.yml index 39d6f36..9cc6337 100644 --- a/.config/alacritty.yml +++ b/.config/alacritty.yml @@ -9,6 +9,8 @@ window: decorations: none + dynamic_title: true + scrolling: history: 10000 @@ -65,16 +67,12 @@ colors: cyan: '#6fc3df' white: '#fcfcfc' -visual_bell: - duration: 0 - background_opacity: 0.9 selection: semantic_escape_chars: "" save_to_clipboard: true -dynamic_title: true cursor: style: Beam diff --git a/.config/git/config b/.config/git/config index c291f3f..d1e8785 100644 --- a/.config/git/config +++ b/.config/git/config @@ -1,91 +1,103 @@ [hub] - protocol = ssh + protocol = ssh [http] - sslVerify = true + sslVerify = true [user] - name = deadguy - email = adeadguy@protonmail.com + name = DeadGit + email = adeadgit@gmail.com + +[include] + path = config.local + +[sendemail] + smtpserver = smtp.gmail.com + smtpuser = adeadgit@gmail.com + chainreplyto = false + suppresscc = self + confirm = auto + smtpencryption = tls + smtpserverport = 587 [core] - editor = nvr --remote-wait-silent - excludesfile = /home/deadguy/.config/git/gitignore - autocrlf = input - whitespace = warn - pager = delta --plus-color="#012800" --minus-color="#340001" + editor = nvr --remote-wait-silent + autocrlf = input + whitespace = warn + excludesfile = /home/deadguy/.config/git/gitignore + pager = delta --plus-color="#012800" --minus-color="#340001" [interactive] - diffFilter = delta --color-only + diffFilter = delta --color-only [web] - browser = firefox + browser = firefox [credential] - helper = /usr/libexec/git-core/git-credential-libsecret + helper = /usr/libexec/git-core/git-credential-libsecret [merge] - tool = nvr - conflictstyle = diff3 + tool = nvr + conflictstyle = diff3 [mergetool "nvr"] - cmd = nvr -s -d $LOCAL $BASE $REMOTE $MERGED -c 'wincmd J | wincmd =' + cmd = nvr -s -d $LOCAL $BASE $REMOTE $MERGED -c 'wincmd J | wincmd =' [diff] - tool = nvr + tool = nvr [difftool "nvr"] - cmd = nvr -s -d $LOCAL $REMOTE + cmd = nvr -s -d $LOCAL $REMOTE [commit] - gpgsign = true - verbose = true + gpgsign = true + verbose = true [status] - branch = true + branch = true [color] - diff = auto - status = auto - branch = auto - ui = true + diff = auto + status = auto + branch = auto + ui = true [rerere] - enabled = true + enabled = true [grep] - lineNumber = true - extendRegexp = true + lineNumber = true + extendRegexp = true [color "branch"] - remote = red bold - current = yellow bold - local = yellow + remote = red bold + current = yellow bold + local = yellow [color "status"] - added = yellow bold - changed = red bold - untracked = red - header = cyan bold - branch = yellow bold + added = yellow bold + changed = red bold + untracked = red + header = cyan bold + branch = yellow bold [color "grep"] - separator = green bold - filename = green - linenumber = blue bold -[color "diff-highlight"] - oldNormal = red bold - oldHighlight = red bold 52 - newNormal = green bold - newHighlight = green bold 22 + separator = green bold + filename = green + linenumber = blue bold [color "diff"] - meta = yellow - frag = magenta bold - commit = yellow bold - old = red bold - new = green bold - whitespace = red reverse + meta = yellow + frag = magenta bold + commit = yellow bold + old = red bold + new = green bold + whitespace = red reverse +[color "diff-highlight"] + oldNormal = red bold + oldHighlight = red bold 52 + newNormal = green bold + newHighlight = green bold 22 [gpg] - program = gpg2 + program = gpg2 [log] - decorate = short + decorate = short diff --git a/.config/nvim/coc-settings.json b/.config/nvim/coc-settings.json index 3d0927c..fff1cbf 100644 --- a/.config/nvim/coc-settings.json +++ b/.config/nvim/coc-settings.json @@ -1,6 +1,22 @@ { "coc.preferences.hoverTarget": "float", + "coc.preferences.formatOnSaveFiletypes": [ + "javascript", + "typescript", + "typescriptreact", + "json", + "javascriptreact", + "typescript.tsx", + "graphql", + "css", + "html" + ], "diagnostic.displayByAle": true, + "diagnostic.infoSign": "● ", + "diagnostic.errorSign": " ", + "diagnostic.warningSign": " ", + "diagnostic.messageTarget": "float", + "diagnostic.enableMessage": "always", "explorer.width": 25, "explorer.icon.enableNerdfont": true, "explorer.icon.enableVimDevicons": false, diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index 6aae89d..aca95a5 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -99,13 +99,6 @@ endfunction function! CmdLine(str) call feedkeys(':' . a:str) endfunction - -function! s:new_mail() - let l:path = system('mktemp --tmpdir XXXXXXXXXX.eml') - execute 'sp' l:path - 0r ~/.config/nvim/templates/skeleton.eml | w | $ -endfunction -command! Mail call s:new_mail() " }}} " AutoCommands {{{ if !exists('autocommands_loaded') && has('autocmd') @@ -117,8 +110,10 @@ if !exists('autocommands_loaded') && has('autocmd') aug END aug term_stuff - au TermOpen * setlocal nonumber norelativenumber laststatus=0 + au TermOpen * setlocal nonumber norelativenumber au TermOpen * setlocal signcolumn=no noruler nocursorline scrolloff=0 + au TermOpen * setlocal statusline=%{b:term_title} + au BufEnter term://* startinsert aug END aug miscs @@ -146,7 +141,6 @@ if !exists('autocommands_loaded') && has('autocmd') au FileType typescript,json setlocal formatexpr=CocAction('formatSelected') au FileType gitcommit,gitrebase,gitconfig set bufhidden=delete au BufNewFile,BufRead requirements*.txt set syntax=python - au BufRead,BufNewFile /tmp/neomutt* set filetype=mail aug END aug statusline @@ -165,26 +159,20 @@ if !exists('autocommands_loaded') && has('autocmd') endif " }}} " {{{ Ale -let g:ale_use_global_executables = 1 -let g:ale_completion_enabled = 0 -let g:ale_linters_explicit = 1 let g:ale_lint_delay = 0 -let g:ale_lint_on_text_changed = 'normal' -let g:ale_lint_on_insert_leave = 1 +let g:ale_disable_lsp = 1 let g:ale_fix_on_save = 1 +let g:ale_linters_explicit = 1 +let g:ale_use_global_executables = 1 let g:ale_close_preview_on_insert = 1 let g:ale_sign_highlight_linenrs = 1 +let g:ale_set_highlights = 1 +let g:ale_set_signs = 1 +let g:ale_javascript_eslint_suppress_missing_config = 1 let g:ale_sign_error = '' let g:ale_sign_warning = '' let g:ale_sign_info = '●' -let g:ale_virtualtext_cursor = 1 let g:ale_loclist_msg_format = '[%linter%] %s% (code)% [%severity%]' -let g:ale_set_highlights = 1 -let g:ale_set_signs = 1 -let g:ale_python_mypy_options = '--ignore-missing-imports' -let g:ale_python_pylint_options = '--disable=C' -let g:ale_python_flake8_options = '--ignore=E221' -let g:move_key_modifier = 'N' let g:ale_linter_aliases = { \ 'jsx': ['css', 'javascript'], @@ -202,7 +190,6 @@ let g:ale_linters = { \ 'sh': ['shellcheck'], \ 'vim': ['vint'], \ 'tex': ['chktex'], -\ 'python': ['pyls', 'flake8', 'pylint'] \} let g:ale_fixers = { \ '*': ['remove_trailing_lines', 'trim_whitespace'], @@ -213,8 +200,9 @@ let g:ale_fixers = { \ 'html': ['prettier_standard'], \ 'scss': ['stylelint'], \ 'css': ['stylelint'], +\ 'bash': ['shfmt'], +\ 'sh': ['shfmt'], \ 'markdown': ['prettier_standard'], -\ 'python': ['autopep8', 'isort', 'yapf'] \} let g:ale_pattern_options = { \ '\.min\.js$': {'ale_linters': [], 'ale_fixers': []}, @@ -225,31 +213,35 @@ nmap (ale_previous_wrap) nmap (ale_next_wrap) " }}} " CoC {{{ -let g:coc_global_extensions = ['coc-lists', 'coc-highlight', 'coc-explorer', 'coc-snippets', 'coc-python', 'coc-tsserver', 'coc-css', 'coc-html', 'coc-json', 'coc-emmet'] +let g:coc_global_extensions = ['coc-lists', 'coc-highlight', 'coc-explorer', 'coc-snippets', 'coc-tsserver', 'coc-css', 'coc-html', 'coc-json', 'coc-emmet'] " Lists nnoremap :CocList -S --ignore-case helptags nnoremap :CocList -S --ignore-case files nnoremap :CocList --normal buffers nnoremap :CocList windows -nnoremap :CocList snippets +nnoremap :CocList snippets " Explorer nnoremap :CocCommand explorer " Config nnoremap :CocConfig -inoremap - \ pumvisible() ? coc#_select_confirm() : - \ coc#expandableOrJumpable() ? "\=coc#rpc#request('doKeymap', ['snippets-expand-jump',''])\" : - \ check_back_space() ? "\" : - \ coc#refresh() -inoremap pumvisible() ? "\" : "\" - function! s:check_back_space() abort let col = col('.') - 1 return !col || getline('.')[col - 1] =~# '\s' endfunction +inoremap + \ pumvisible() ? "\" : + \ coc#jumpable() ? "\=coc#rpc#request('snippetNext',[])\" : + \ check_back_space() ? "\" : + \ coc#refresh() + +inoremap + \ pumvisible() ? "\" : + \ coc#jumpable() ? "\=coc#rpc#request('snippetPrev',[])\" : + \ "\" + " to confirm completion if exists('*complete_info') inoremap complete_info()["selected"] != "-1" ? "\" : "\u\" @@ -279,9 +271,9 @@ endfunction nnoremap rn (coc-rename) "}}} "{{{ Polyglot -let g:polyglot_disabled = ['javascript', 'python'] let g:vim_markdown_toc_autofit = 1 let g:markdown_fenced_languages = ['vim', 'help'] +let g:javascript_plugin_jsdoc = 1 let g:vim_jsx_pretty_colorful_config = 1 let g:jsx_ext_required = 1 let g:tex_flavor='latex' @@ -298,8 +290,6 @@ let g:vimtex_view_use_temp_files = 2 call plug#begin(stdpath('data') . '/plugged') Plug 'dense-analysis/ale' Plug 'lervag/vimtex', {'for': 'latex'} -Plug 'othree/yajs.vim', {'for': 'javascript'} -Plug 'othree/es.next.syntax.vim', {'for': 'javascript'} Plug 'neoclide/coc.nvim', {'branch': 'release'} Plug 'sheerun/vim-polyglot' Plug 'tmsvg/pear-tree' @@ -385,7 +375,6 @@ function! StatusLine() abort let l:statusline.='%1* ' let l:statusline.='%= ' let l:statusline.=coc#status() - let l:statusline.=' %6*' let l:statusline.=LinterStatus() let l:statusline.='%3* %p%% %c ' let l:statusline.='' @@ -529,6 +518,8 @@ nnoremap mz:m-2`z " My vim wants to enter all the time, enter all the time nnoremap + i +nnoremap o :call append(line('.'), '') +nnoremap O :call append(line('.')-1, '') " Unhighlight search terms nnoremap :noh=has('diff')?'diffupdate':'' @@ -540,8 +531,8 @@ nnoremap k v:count ? (v:count > 5 ? "m'" . v:count : '') . " Line movements noremap g noremap g -nnoremap Y 0y$ -nnoremap y y$ +nnoremap y 0y$ +nnoremap Y y$ " Tab movement nnoremap tn :tabnew diff --git a/.config/sxhkd/sxhkdrc b/.config/sxhkd/sxhkdrc index 561e4b0..9856e81 100644 --- a/.config/sxhkd/sxhkdrc +++ b/.config/sxhkd/sxhkdrc @@ -48,8 +48,8 @@ super + shift + {x,m,g} super + ctrl + m espejo -super + {a,x,i,v,z} - alacritty {_,--class=flota,--class=flota -e connman-ncurses,--class=flota -e pulsemixer,--class=multi -e termux} +super + {a,x,v,z} + alacritty {_,--class=flota,--class=flota -e pulsemixer,--class=multi -e termux} super + space j4-dmenu-desktop --dmenu="dmenu -i -w 250 -p ' ' " --no-generic diff --git a/.config/tmux/tmux.conf b/.config/tmux/tmux.conf index a0df897..639e43d 100644 --- a/.config/tmux/tmux.conf +++ b/.config/tmux/tmux.conf @@ -40,7 +40,7 @@ set -g pane-border-style fg=colour0,dim set -g pane-active-border-style fg=colour0,dim set -g set-titles on set -g status-interval 60 -set -g mode-style fg=colour0,bg=yellow +set -g mode-style fg=colour0,bg=yellow set -g message-command-style bg=colour0,fg=colour13 set -g message-style 'bg=#151515,fg=white,italics' set -g status-style bg=default,fg=colour7 diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc index c549f01..3ec1739 100644 --- a/.config/zsh/.zshrc +++ b/.config/zsh/.zshrc @@ -80,28 +80,13 @@ setopt PROMPT_SUBST # Anonymous function to avoid leaking variables. function () { - # Check for tmux by looking at $TERM, because $TMUX won't be propagated to any - # nested sudo shells but $TERM will. - local TMUXING=$([[ "$TERM" =~ "tmux" ]] && echo tmux) - if [ -n "$TMUXING" -a -n "$TMUX" ]; then - # In a a tmux session created in a non-root or root shell. - local LVL=$(($SHLVL - 1)) - else - # Either in a root shell created inside a non-root tmux session, - # or not in a tmux session. local LVL=$SHLVL - fi if [[ $EUID -eq 0 ]]; then local SUFFIX='%F{yellow}%n%f'$(printf '%%F{yellow}>%.0s%%f' {1..$LVL}) else local SUFFIX=$(printf '>%.0s%%f' {1..$LVL}) fi export PROMPT="%(?..%{%F{red}%}(%?%)%{%f%} )%F{green}${SSH_TTY:+%n@%m}%f%B${SSH_TTY:+:}%b%F{blue}%B%2~%b%F{yellow}%B%(1j.*.)%b%f %B${SUFFIX}%b " - if [[ -n "$TMUXING" ]]; then - # Outside tmux, ZLE_RPROMPT_INDENT ends up eating the space after PS1, and - # prompt still gets corrupted even if we add an extra space to compensate. - export ZLE_RPROMPT_INDENT=0 - fi } export SPROMPT="zsh: correct %F{red}'%R'%f to %F{green}'%r'%f [%B%Uy%u%bes, %B%Un%u%bo, %B%Ue%u%bdit, %B%Ua%u%bbort]? " diff --git a/.config/zsh/aliases.zsh b/.config/zsh/aliases.zsh index 8bc9208..94ed613 100644 --- a/.config/zsh/aliases.zsh +++ b/.config/zsh/aliases.zsh @@ -3,18 +3,16 @@ alias \ vdi='nvim -d' \ se='sudoedit' \ gdl='gallery-dl' \ - m='neomutt' \ am='alsamixer' \ pm='pulsemixer' \ nb='newsboat -q' \ v='$EDITOR' \ play='ncmpcpp' \ - py='python ' \ x='xui' \ - yt='mpsyt' \ z='zathura' \ - pudb='python -m pudb.run' \ - irc='weechat -d "$XDG_CONFIG_HOME"/weechat' + py='python ' \ + pyserv='python -m http.server' \ + irc='catgirl freenode' # XBPS alias \ xk='xbps-query' \ @@ -78,13 +76,11 @@ alias \ # Colores para pintar este twist alias \ diff='diff --color=auto' \ - bat='bat --color=always --terminal-width=-10' \ ls='ls -AFpt --color=always --group-directories-first' \ grep='grep --color=tty -d skip' \ dmesg='dmesg --color=always' \ dir='dir --color=always' \ vsv='sudo vsv -c yes' \ - vpm='sudo vpm --color=yes' # Con opciones por defecto alias \ @@ -105,7 +101,6 @@ alias \ sudo='sudo ' \ reboot='sudo reboot' \ shutdown='sudo shutdown -h now' \ - chau='bspc quit 1' \ path='echo -e ${PATH//:/\\n}' \ wp='sxiv-rifle ~/img/wallpaper >/dev/null 2>&1' \ pwn='chmod +x' \ diff --git a/.local/bin/powermenu b/.local/bin/powermenu index becc105..4841852 100755 --- a/.local/bin/powermenu +++ b/.local/bin/powermenu @@ -5,7 +5,7 @@ case $chosen in "Apagar") loginctl poweroff;; "Reiniciar") loginctl reboot;; "Suspender") loginctl suspend;; - "Cerrar") xset s activate;; + "Bloquear") xset s activate;; "Salir") loginctl terminate-user "$(id -u "$USER")";; *) exit 0;; esac diff --git a/.xinitrc b/.xinitrc index 9020b37..5c700a6 100644 --- a/.xinitrc +++ b/.xinitrc @@ -6,6 +6,7 @@ xsetroot -cursor_name left_ptr & randbg & xcompmgr & equiset & +mpd & xss-lock -l -- exeflock4 & exec runsvdir -P ~/.local/service.x 'log: ...........................................................................................................................................................................................................................................................................................................................................................................................................' diff --git a/.zshenv b/.zshenv index 28bcb5c..1e12b44 100644 --- a/.zshenv +++ b/.zshenv @@ -5,9 +5,9 @@ else export EDITOR="nvim" fi -export TERMINAL="alacritty" export VISUAL="$EDITOR" export GIT_EDITOR="$EDITOR" +export TERMINAL="alacritty" export BROWSER="firefox" export READER="zathura" export VIDEO="mpv" @@ -23,8 +23,6 @@ export TIME_STYLE="long-iso" export BLOCK_SIZE="'1" export QUOTING_STYLE=literal export HIGHLIGHT_OPTIONS='--out-format="ansi" --style="pablo"' -export BAT_STYLE="numbers,changes,header" -export BAT_THEME="TwoDark" export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/gtkrc-2.0" export QT_QPA_PLATFORMTHEME="gtk3" @@ -41,15 +39,10 @@ export SSH_ASKPASS="/bin/gnome-ssh-askpass" export PASSWORD_STORE_DIR="$XDG_DATA_HOME/pass" eval $(keychain --dir ~/.local/share/keychain --quiet --eval --noask --agents ssh,gpg id_rsa) -export WINEPREFIX="${XDG_DATA_HOME:-$HOME/.local/share}/wineprefixes/default" export NOTMUCH_CONFIG="$XDG_CONFIG_HOME/notmuch-config" -export INPUTRC="$XDG_CONFIG_HOME/inputrc" export WGETRC="$XDG_CONFIG_HOME/wget/wgetrc" -export IPYTHONDIR="$XDG_CONFIG_HOME/ipython" -export JUPYTER_CONFIG_DIR="$XDG_CONFIG_HOME/jupyter" export WEECHAT_HOME="$XDG_CONFIG_HOME/weechat" export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc" -export PYLINTHOME="$XDG_CACHE_HOME/pylint" export NODE_REPL_HISTORY="$XDG_DATA_HOME/node_repl_history" export RANDFILE="$XDG_DATA_HOME/rnd" export GOPATH="$XDG_DATA_HOME/go" diff --git a/doc/xbpaketes b/doc/xbpaketes index 4813245..9c5a343 100644 --- a/doc/xbpaketes +++ b/doc/xbpaketes @@ -12,32 +12,27 @@ alsa-utils android-udev-rules atool audacity -autopep8 base-system bat bc bspwm cadence +catgirl chrony -chuck connman connman-ncurses crispy-doom cryptsetup ctags -dejavu-fonts-ttf delta dfc dunst elogind -entr -faac fd -fdk-aac-devel -fdkaac ffmpeg figlet file-roller +filezilla firefox fzf gallery-dl @@ -57,7 +52,7 @@ hub i3lock-color intel-ucode isync -j4-dmenu-desktop +iwd jack-devel jq keychain @@ -69,14 +64,12 @@ libressl-devel librsvg librsvg-utils libsndfile-devel -linux5.6 lynx maim mblaze mdadm mediainfo mlocate -mmutils mpc mpd mpv @@ -99,7 +92,6 @@ p7zip pass patch pd -perl-File-MimeInfo pinentry-gtk pinentry-tty pkg-config @@ -107,22 +99,12 @@ polkit powertop pulseaudio pulsemixer -pylint python3 -python3-BeautifulSoup4 -python3-ipython -python3-isort -python3-language-server -python3-lxml -python3-mccabe -python3-mypy python3-pip -python3-pycodestyle -python3-pyflakes python3-vint -python3-yapf setxkbmap shellcheck +shfmt simple-mtpfs snooze socklog-void @@ -132,7 +114,6 @@ texlive-bin tmux toilet transmission -tuir udevil unclutter-xfixes unrar