diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 6b8860557..7ec1c319f 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -17,8 +17,6 @@ updates: interval: daily time: '04:00' open-pull-requests-limit: 10 - reviewers: - - kornicameister labels: - dependabot - automerge diff --git a/.github/workflows/automerge.yml b/.github/workflows/automerge.yml index 0d2cebebb..f3431ba9d 100644 --- a/.github/workflows/automerge.yml +++ b/.github/workflows/automerge.yml @@ -24,7 +24,7 @@ jobs: runs-on: ubuntu-20.04 steps: - name: automerge - uses: pascalgn/automerge-action@v0.13.0 + uses: pascalgn/automerge-action@v0.13.1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} MERGE_REMOVE_LABELS: automerge diff --git a/.github/workflows/misspell.yml b/.github/workflows/misspell.yml index 372e401bd..f7b4c2343 100644 --- a/.github/workflows/misspell.yml +++ b/.github/workflows/misspell.yml @@ -11,7 +11,7 @@ jobs: steps: - uses: actions/checkout@v2 - uses: sobolevn/misspell-fixer-action@0.1.0 - - uses: peter-evans/create-pull-request@v3.6.0 + - uses: peter-evans/create-pull-request@v3.7.0 with: token: ${{ secrets.GITHUB_TOKEN }} title: "Dotfiles spell good must be..." diff --git a/bin/top_mem b/bin/top_mem new file mode 100755 index 000000000..ec4ee779d --- /dev/null +++ b/bin/top_mem @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +# Display the top applications of memory usage +# http://www.cyberciti.biz/faq/linux-check-memory-usage/#comment-51021 + +while read -r command percent rss; do + if [[ "${command}" != "COMMAND" ]]; then + rss="$(bc <<<"scale=2;${rss}/1024")" + fi + printf " %-26s%-8s%s\n" "${command}" "${percent}" "${rss} MB" | + sed 's/COMMAND/PROGRAM/' | sed 's/RSS MB/#MEM/' +done < <(ps -A --sort -rss -o comm,pmem,rss | head -n 20) diff --git a/config/i3/config b/config/i3/config index 3421096b2..1b8723c64 100644 --- a/config/i3/config +++ b/config/i3/config @@ -43,11 +43,11 @@ client.background $bg ###--- Autostart ---### exec_always --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 -exec_always --no-startup-id "$HOME/.config/polybar/launch.sh" +exec_always --no-startup-id feh --bg-center "$HOME/.dotfiles/wallpapers/05_lake.jpg" exec_always --no-startup-id wal --vte -R +exec_always --no-startup-id "$HOME/.config/polybar/launch.sh" exec --no-startup-id wal-vtop exec --no-startup-id picom -cC # compositor -exec --no-startup-id nitrogen --restore # wallpaper exec --no-startup-id xset s 480 dpms 600 600 600 # powersavings for display: exec --no-startup-id sleep 2 ; /usr/bin/dunst # notifications exec --no-startup-id dex -a -s /etc/xdg/autostart/:~/.config/autostart # dex execute .desktop files @@ -67,26 +67,28 @@ bindsym $mod+d exec --no-startup-id i3-dmenu-desktop # change focus: bindsym $mod+j focus left -bindsym $mod+k focus down -bindsym $mod+u focus up -bindsym $mod+ntilde focus right - -# alternatively, you can use the cursor keys: bindsym $mod+Left focus left + +bindsym $mod+k focus down bindsym $mod+Down focus down + +bindsym $mod+u focus up bindsym $mod+Up focus up + +bindsym $mod+ntilde focus right bindsym $mod+Right focus right # move focused window: bindsym $mod+Shift+j move left -bindsym $mod+Shift+k move down -bindsym $mod+Shift+l move up -bindsym $mod+Shift+ntilde move right - -# alternatively, you can use the cursor keys: bindsym $mod+Shift+Left move left + +bindsym $mod+Shift+k move down bindsym $mod+Shift+Down move down + +bindsym $mod+Shift+l move up bindsym $mod+Shift+Up move up + +bindsym $mod+Shift+ntilde move right bindsym $mod+Shift+Right move right # split in horizontal orientation: @@ -154,9 +156,7 @@ bindsym $mod+Shift+7 move container to workspace $ws7 bindsym $mod+Shift+8 move container to workspace $ws8 bindsym $mod+Shift+9 move container to workspace $ws9 -# reload the configuration file: bindsym $mod+Shift+c reload -# restart i3 inplace (preserves your layout/session, can be used to upgrade i3): bindsym $mod+Shift+r restart # exit i3 (logs you out of your X session): @@ -205,13 +205,12 @@ exec_always --no-startup-id "avizo-service" for_window [class="Avizo"] border pixel 0 floating enable # App shortcuts -bindsym $mod+b exec "/usr/bin/brave-nightly" -bindsym $mod+Shift+b exec "/usr/bin/brave-nightly --incognito" +bindsym $mod+b exec "/usr/bin/brave" +bindsym $mod+Shift+b exec "/usr/bin/brave --incognito" bindsym $mod+n exec "/usr/bin/thunar" bindsym $mod+l exec i3lock -i ~/.config/i3/i3-lock-screen.png -t -f bindsym Print exec "scrot ~/%Y-%m-%d-%T-screenshot.png" - # rofi bindings fancy application menu bindsym $mod+i exec rofi -modi drun -show drun -line-padding 4 \ -columns 2 -padding 50 -hide-scrollbar \ @@ -223,7 +222,6 @@ bindsym $mod+s exec ssh -show window -line-padding 4 \ -lines 6 -padding 50 -hide-scrollbar \ -show-icons -drun-icon-theme "Arc-X-D" - # per window customizations for_window [class="Spotify"] move to workspace $ws9 for_window [class="jetbrains-pycharm" title="^ $"] floating enable @@ -234,4 +232,6 @@ for_window [class="Xsane" instance="xsane"] floating enable for_window [class="Pavucontrol" instance="pavucontrol"] floating enable for_window [class="qt5ct" instance="qt5ct"] floating enable for_window [class="Bluetooth-sendto" instance="bluetooth-sendto"] floating enable + + for_window [class="Pamac-manager"] floating enable diff --git a/config/polybar/config.ini b/config/polybar/config.ini index 59551e179..397eaab9a 100644 --- a/config/polybar/config.ini +++ b/config/polybar/config.ini @@ -21,6 +21,8 @@ red = ${xrdb:color1:#FF5250} green = ${xrdb:color2:#43a047} yellow = ${xrdb:color3:#fdd835} +active = ${xrdb:color10:#222} +inactive = ${xrdb:color11:#222} alert = ${xrdb:color9:#222} [bar] @@ -54,7 +56,7 @@ module-margin-right = 0 font-0 = "Iosevka Nerd Font:pixelsize=9;3" font-1 = "Iosevka Nerd Font:pixelsize=11;4" -font-2 = "Font Awesome 5 Free;9;4" +font-2 = "Font Awesome 5 Free;8;4" [bar/top] inherit = bar/main @@ -395,3 +397,36 @@ format-foreground = ${colors.yellow} hook-0 = echo "%{A1:notify-send "DUNST_COMMAND_PAUSE" && polybar-msg hook dunst 2:}%{A}" & hook-1 = echo "%{A1:notify-send "DUNST_COMMAND_RESUME" && polybar-msg hook dunst 1:}%{A}" & + +[module/workspaces] +type = internal/xworkspaces + +pin-workspaces = true +enable-click = true +enable-scroll = true + +format-font = 3 +icon-default = "" + +format = +format-background = ${color.background-alt} +format-padding = 0 + +label-monitor = %name% + +label-active = %index% %icon% +label-active-foreground = ${color.primary} +label-active-overline = ${color.active} + +label-occupied = %icon% +label-occupied-foreground = ${color.inactive} + +label-urgent = %icon% +label-urgent-foreground = ${color.alert} + +label-empty = %icon% + +label-active-padding = 1 +label-urgent-padding = 1 +label-occupied-padding = 1 +label-empty-padding = 1 diff --git a/config/polybar/modules.ini b/config/polybar/modules.ini index 5ddbfe7d3..d03b6a6bd 100644 --- a/config/polybar/modules.ini +++ b/config/polybar/modules.ini @@ -304,91 +304,3 @@ bar-volume-foreground-4 = ${color.red} bar-volume-empty = ${bar.empty} bar-volume-empty-foreground = ${color.foreground-alt} - -;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ - - -;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ - -[module/workspaces] -type = internal/xworkspaces - -; Only show workspaces defined on the same output as the bar -; -; Useful if you want to show monitor specific workspaces -; on different bars -; -; Default: false -pin-workspaces = true - -; Create click handler used to focus desktop -; Default: true -enable-click = true - -; Create scroll handlers used to cycle desktops -; Default: true -enable-scroll = true - -; icon-[0-9]+ = ; -; NOTE: The desktop name needs to match the name configured by the WM -; You can get a list of the defined desktops using: -; $ xprop -root _NET_DESKTOP_NAMES -icon-0 = 1; -icon-1 = 2; -icon-2 = 3; -icon-3 = 4; -icon-4 = 5; -icon-default =  - - -; Available tags: -; -; - gets replaced with -; Default: -format = -format-background = ${color.background} -format-padding = 0 - -; Available tokens: -; %name% -; Default: %name% -label-monitor = %name% - -; Available tokens: -; %name% -; %icon% -; %index% -; Default: %icon% %name% -label-active = %icon% -label-active-foreground = ${color.red} -label-active-overline = ${color.red} - -; Available tokens: -; %name% -; %icon% -; %index% -; Default: %icon% %name% -label-occupied = %icon% -label-occupied-foreground = ${color.yellow} - -; Available tokens: -; %name% -; %icon% -; %index% -; Default: %icon% %name% -label-urgent = %icon% -label-urgent-foreground = ${color.green} - -; Available tokens: -; %name% -; %icon% -; %index% -; Default: %icon% %name% -label-empty = %icon% - -label-active-padding = 1 -label-urgent-padding = 1 -label-occupied-padding = 1 -label-empty-padding = 1 - -;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ diff --git a/config/systemd/user/.gitignore b/config/systemd/user/.gitignore new file mode 100644 index 000000000..5fcfbfa8e --- /dev/null +++ b/config/systemd/user/.gitignore @@ -0,0 +1 @@ +*.wants/ diff --git a/config/systemd/user/docker-prune.service b/config/systemd/user/docker-prune.service new file mode 100644 index 000000000..124bc212b --- /dev/null +++ b/config/systemd/user/docker-prune.service @@ -0,0 +1,10 @@ +[Unit] +Description=docker system pruner service + +[Service] +Type=oneshot +ExecStartPre=echo "Prunning docker" +ExecStart=docker system prune -a -f ; docker volume prune -f + +[Install] +WantedBy=docker-prune.timer diff --git a/config/systemd/user/docker-prune.timer b/config/systemd/user/docker-prune.timer new file mode 100644 index 000000000..1ff44f993 --- /dev/null +++ b/config/systemd/user/docker-prune.timer @@ -0,0 +1,11 @@ +[Unit] +Description=Run docker prune in intervals + +[Timer] +OnStartupSec=1min +OnCalendar=daily +Persistent=true + +[Install] +WantedBy=timers.target + diff --git a/config/systemd/user/eos-update-notifier.service b/config/systemd/user/eos-update-notifier.service new file mode 100644 index 000000000..a052a86ef --- /dev/null +++ b/config/systemd/user/eos-update-notifier.service @@ -0,0 +1,10 @@ +[Unit] +Description=EOS update notifier service + +[Service] +Type=oneshot +Environment=DISPLAY=:0 +ExecStart=/usr/bin/eos-update-notifier -systemd + +[Install] +WantedBy=eos-update-notifier.timer diff --git a/config/systemd/user/eos-update-notifier.timer b/config/systemd/user/eos-update-notifier.timer new file mode 100644 index 000000000..8b6834811 --- /dev/null +++ b/config/systemd/user/eos-update-notifier.timer @@ -0,0 +1,10 @@ +[Unit] +Description=Run EOS update notifier periodically + +[Timer] +OnStartupSec=30sec +OnCalendar=daily +Persistent=true + +[Install] +WantedBy=timers.target diff --git a/dependencies/goenv b/dependencies/goenv index d970d0a3e..037dce09b 160000 --- a/dependencies/goenv +++ b/dependencies/goenv @@ -1 +1 @@ -Subproject commit d970d0a3e32c927814be7394b376412777a394fd +Subproject commit 037dce09b26b409a87f1b6801f40575093308c11 diff --git a/dependencies/node-build b/dependencies/node-build index b5a8d7339..be9b55391 160000 --- a/dependencies/node-build +++ b/dependencies/node-build @@ -1 +1 @@ -Subproject commit b5a8d73398af455b90c90668ead6d7b225542b53 +Subproject commit be9b55391e9663d101abaeb0c82fac53fd671346 diff --git a/dependencies/pyenv b/dependencies/pyenv index 569992f25..80e418eca 160000 --- a/dependencies/pyenv +++ b/dependencies/pyenv @@ -1 +1 @@ -Subproject commit 569992f25fc22717b54bb74cbf0cc362bbf50e01 +Subproject commit 80e418eca535b9c7cbdd0f8557586eaaf872000d diff --git a/dotbot b/dotbot index 4ec846cda..472223300 160000 --- a/dotbot +++ b/dotbot @@ -1 +1 @@ -Subproject commit 4ec846cdad4c5f6996523e7015f0b36a6b40e9f6 +Subproject commit 472223300fcbe308853b6f57ff03eec21f611809 diff --git a/install b/install index f0da43855..66235f4f3 100755 --- a/install +++ b/install @@ -109,7 +109,7 @@ install_packages() { log_notice "Installing browsers" "${icon}" yay -Syq --needed --noconfirm --combinedupgrade --batchinstall \ - brave-nightly-bin \ + brave-bin \ firefox \ google-chrome-dev @@ -122,6 +122,7 @@ install_packages() { yay -Syq --needed --noconfirm --combinedupgrade --batchinstall \ docker \ docker-compose \ + ctop \ fuse-overlayfs \ hadolint-bin \ virtualbox && { @@ -157,6 +158,7 @@ EOF yay -Syq --needed --noconfirm --combinedupgrade --batchinstall \ ttf-iosevka \ ttf-font-awesome \ + ttf-material-design-icons \ ant-dracula-gtk-theme log_notice "Installing " "${icon}" @@ -202,6 +204,7 @@ _remove_redundant_packages() { alacritty \ xterm \ terminator \ + nitrogen \ xterm || true _yay_clean } @@ -583,8 +586,9 @@ gen_ssh_key() { local name="${1}" local password="${2}" local comment="${3}" + local type="${4:-ed25519}" ssh-keygen \ - -t ed25519 \ + -t "${type}" \ -b 4096 \ -C "${comment}" \ -f "${HOME}/.ssh/${name}" \ diff --git a/neovim-requirements.txt b/neovim-requirements.txt index 30d57f45c..9724e002a 100644 --- a/neovim-requirements.txt +++ b/neovim-requirements.txt @@ -3,7 +3,7 @@ msgpack==1.0.2 neovim==0.3.1 neovim-remote==2.4.0 ; python_version > '3.0' -pynvim==0.4.2 +pynvim==0.4.3 python-language-server==0.36.2 jedi>=0.17.2 diff --git a/package.json b/package.json index 8a79f29e2..c37dcacbe 100644 --- a/package.json +++ b/package.json @@ -4,13 +4,14 @@ "version": "0.0.0", "private": true, "dependencies": { - "npm": "6.14.11", + "npm": "7.6.3", "neovim": "4.9.0", - "typescript": "4.1.3", - "@elm-tooling/elm-language-server": "2.0.0", + "prettier": "2.2.1", + "typescript": "4.2.3", + "@elm-tooling/elm-language-server": "2.0.3", "bash-language-server": "1.17.0", - "vim-language-server": "2.1.2", - "dockerfile-language-server-nodejs": "0.2.2", - "yaml-language-server": "0.14.0" + "vim-language-server": "2.1.3", + "dockerfile-language-server-nodejs": "0.3.0", + "yaml-language-server": "0.16.0" } } diff --git a/python-system-requirements.txt b/python-system-requirements.txt index ab79bd9c2..4c81c3c1a 100644 --- a/python-system-requirements.txt +++ b/python-system-requirements.txt @@ -1,13 +1,13 @@ -pip==20.3.3 +pip==21.0 -setuptools==51.1.2 ; python_version >= '3.0' +setuptools==54.1.2 ; python_version >= '3.0' setuptools==44.0.0 ; python_version < '3.0' wheel==0.36.2 -mypy==0.790; python_version >= '3.0' --no-binary mypy +mypy==0.812; python_version >= '3.0' --no-binary mypy -flake8==3.8.4; -flake8-bugbear==20.11.1; python_version >= '3.0' +flake8==3.9.0; +flake8-bugbear==21.3.2; python_version >= '3.0' flake8-commas==2.0.0 flake8-quotes==3.2.0 flake8-print==4.0.0; python_version >= '3.0' @@ -17,8 +17,8 @@ flake8-bandit==2.1.2 flake8-comprehensions==3.3.1; python_version >= '3.0' flake8-comprehensions==1.4.1; python_version < '3.0' -yapf==0.30.0 +yapf==0.31.0 -cfn-lint==0.44.4 +cfn-lint==0.47.2 wakatime==13.1.0 diff --git a/vim/plugins.vim b/vim/plugins.vim index 9ae8c4bc5..5e2f934b8 100644 --- a/vim/plugins.vim +++ b/vim/plugins.vim @@ -74,7 +74,6 @@ Plug 'vim-scripts/indentpython.vim', {'for': ['python']} Plug 'raimon49/requirements.txt.vim', {'for': ['requirements']} if has('nvim') Plug 'kalekseev/vim-coverage.py', { 'do': ':UpdateRemotePlugins', 'for': ['python'] } - Plug 'numirias/semshi', { 'do': ':UpdateRemotePlugins' } else Plug 'kalekseev/vim-coverage.py', { 'do': '!pip install --user --upgrade neovim', 'for': ['python']} endif @@ -102,6 +101,7 @@ Plug 'farmergreg/vim-lastplace' " open editor where it was Plug 'zinit-zsh/zinit-vim-syntax' " zinit power Plug 'mustache/vim-mustache-handlebars' Plug 'triglav/vim-visual-increment' +Plug 'voldikss/vim-floaterm' Plug 'mboughaba/i3config.vim' " nginx @@ -192,7 +192,9 @@ if has_key(g:plugs, 'vim-airline') let g:airline_left_sep='›' " Slightly fancier than '>' let g:airline_right_sep='‹' " Slightly fancier than '<' - let g:airline#extensions#ale#enabled = 1 + if has_key(g:plugs, 'ale') + let g:airline#extensions#ale#enabled = 1 + endif let g:airline#extensions#tabline#formatter = 'unique_tail_improved' let g:airline#extensions#tabline#enabled = 1 @@ -289,7 +291,9 @@ augroup vim_go_options \ . ' --enable=goimports' \ . ' --enable=misspell' \ . ' --enable=lll --line-length=120' - let g:ale_go_gometalinter_options = '--disable-all --tests' . g:gometalinter_fast . ' --enable=golint' + if has_key(g:plugs, 'ale') + let g:ale_go_gometalinter_options = '--disable-all --tests' . g:gometalinter_fast . ' --enable=golint' + endif augroup END " deoplete settings @@ -333,6 +337,7 @@ if has_key(g:plugs, 'fzf.vim') nmap F :Files nmap c :Commits nmap b :Buffers + nmap h :History nmap (fzf-maps-n) xmap (fzf-maps-x) omap (fzf-maps-o) @@ -340,7 +345,9 @@ if has_key(g:plugs, 'fzf.vim') " floating window let g:fzf_layout = { 'window': { 'width': 0.9, 'height': 0.6 } } augroup END +endif +if has_key(g:plugs, 'ale') " ale settings augroup ale_plugin_settings autocmd! @@ -366,8 +373,9 @@ if has_key(g:plugs, 'fzf.vim') nmap (ale_previous_wrap) nmap (ale_next_wrap) + nmap (ale_rename) nmap (ale_hover) - nmap (ale_go_to_definition) + nmap (ale_go_to_definition_in_vsplit) if has('nvim') autocmd VimEnter * diff --git a/wallpapers/03_flower.jpg b/wallpapers/03_flower.jpg new file mode 100644 index 000000000..19fd1251a Binary files /dev/null and b/wallpapers/03_flower.jpg differ diff --git a/wallpapers/04_python_2.png b/wallpapers/04_python_2.png new file mode 100644 index 000000000..5220d08d7 Binary files /dev/null and b/wallpapers/04_python_2.png differ diff --git a/wallpapers/05_lake.jpg b/wallpapers/05_lake.jpg new file mode 100644 index 000000000..53104dfd9 Binary files /dev/null and b/wallpapers/05_lake.jpg differ diff --git a/zsh/zprofile b/zsh/zprofile index 886abb5e7..4413f3572 100644 --- a/zsh/zprofile +++ b/zsh/zprofile @@ -48,6 +48,13 @@ path=( $JENV_ROOT/bin $path ) +[ $commands[gem] ] && { + path=( + "$(gem environment | grep 'USER INSTALLATION DIRECTORY' | awk -F': ' '{print $2}')/bin" + $path + ) +} + # Less diff --git a/zsh/zshrc b/zsh/zshrc index 76c1a3856..7d3782ec2 100644 --- a/zsh/zshrc +++ b/zsh/zshrc @@ -194,9 +194,20 @@ zinit light direnv/direnv # prompt zinit light-mode for atload'source ~/.p10k.zsh' romkatv/powerlevel10k -# aliases -[ $commands[vtop] ] && [ $commands[wal] ] && alias vtop="vtop --theme wal" +# aliases [programs] +alias vtop="vtop --theme waSl" + [ $commands[nvim] ] && { alias vi='nvim'; alias vim='nvim'; } + +# aliases [ll] +alias ls='exa'; # ls +alias l='exa -lbGF --git'; # long list +alias ll='exa -lbF --git'; # list, size, type, git +alias llm='exa -lbGF --git --sort=modified'; # long list, modified date sort +alias la='exa -lbhHigUmuSa --time-style=long-iso --git --color-scale'; # all list +alias lx='exa -lbhHigUmuSa@ --time-style=long-iso --git --color-scale;'; # all + extended list +alias ls='exa -1'; # one column, just names +alias lt='exa --tree --level=2'; # tree