From aa4c6f4b01d27fc168f3f6af94b16fb77ca94979 Mon Sep 17 00:00:00 2001 From: Adam Veldhousen Date: Mon, 2 Mar 2020 17:49:37 -0600 Subject: [PATCH] updated all configs --- Dockerfile | 2 +- installers/apps/alacritty.sh | 2 +- installers/apps/dotnet.sh | 6 + installers/base.sh | 5 +- installers/linux.sh | 13 +- makefile | 1 + src/.config/compton/compton.conf | 43 ++--- src/.config/i3/config | 68 +++---- src/.config/i3/polybar.sh | 6 +- src/.config/nitrogen/bg-saved.cfg | 4 +- src/.config/polybar/config | 261 ++++++++++++++++----------- src/.config/terminator/config | 14 +- src/.config/tmux/.tmux.conf | 4 + src/.config/vim/.vimrc | 27 ++- src/.gitconfig | 9 +- src/.shell_extensions/aliases.sh | 7 +- src/.shell_extensions/environment.sh | 2 + 17 files changed, 268 insertions(+), 206 deletions(-) create mode 100755 installers/apps/dotnet.sh mode change 100644 => 100755 src/.config/i3/polybar.sh diff --git a/Dockerfile b/Dockerfile index f49dfbc..8f53319 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,7 @@ LABEL net.veldhousen.version=${version} LABEL net.veldhousen.commit=${commit} LABEL net.veldhousen.created=${created} -RUN apt-get update && apt-get install -y sudo apt-utils && apt-get clean +RUN apt-get update -qq && apt-get install -qq -y sudo apt-utils && apt-get clean RUN useradd -G sudo -U -u 1000 -m -s /bin/bash dev \ && echo 'dev:dev' | chpasswd \ && mkdir -p /home/dev/Projects \ diff --git a/installers/apps/alacritty.sh b/installers/apps/alacritty.sh index b10e8fe..807219b 100755 --- a/installers/apps/alacritty.sh +++ b/installers/apps/alacritty.sh @@ -1,4 +1,4 @@ #!/bin/sh ALACRITTY_VERSION=0.3.3; curl -L https://github.com/jwilm/alacritty/releases/download/v${ALACRITTY_VERSION}/Alacritty-v${ALACRITTY_VERSION}-ubuntu_18_04_amd64.deb > /tmp/alacritty.deb; -sudo apt install -y /tmp/alacritty.deb; \ No newline at end of file +sudo apt install -qq -y /tmp/alacritty.deb; \ No newline at end of file diff --git a/installers/apps/dotnet.sh b/installers/apps/dotnet.sh new file mode 100755 index 0000000..2dd6d89 --- /dev/null +++ b/installers/apps/dotnet.sh @@ -0,0 +1,6 @@ +#!/bin/sh + +wget -q https://packages.microsoft.com/config/ubuntu/19.04/packages-microsoft-prod.deb -O /tmp/packages-microsoft-prod.deb; +sudo dpkg -i /tmp/packages-microsoft-prod.deb; +sudo apt-get update -qq; +sudo apt-get install -y -qq dotnet-sdk-3.0; diff --git a/installers/base.sh b/installers/base.sh index c58666f..6b105c1 100755 --- a/installers/base.sh +++ b/installers/base.sh @@ -25,6 +25,7 @@ SRC_DIR=${BASE_DIR}/src; TOOLS_DIR=${BASE_DIR}/tools; CONFIG_DIR=${SRC_DIR}/.config; EXT_DIR=${SRC_DIR}/.shell_extensions; +export APP_INSTALLS="${BASE_DIR}/installers/app"; if [ -d ${HOME_DIR} ]; then echo "installing into ${HOME_DIR}"; @@ -88,11 +89,11 @@ fi #------------------------------------------------------------------ mkdir -p ${HOME_DIR}/.bin; -APP_INSTALLS=${BASE_DIR}/installers/app; - +set -x; source ${APP_INSTALLS}/golang.sh; source ${APP_INSTALLS}/node.sh; source ${APP_INSTALLS}/rust.sh; source ${APP_INSTALLS}/rvm.sh; +set +x; find ${HOME} ! -path "${HOME}/projects" ! -path "${HOME}" | xargs -I {} chown $@ {}; diff --git a/installers/linux.sh b/installers/linux.sh index 6a4fb1f..616dc74 100755 --- a/installers/linux.sh +++ b/installers/linux.sh @@ -16,12 +16,9 @@ elif [ -z "$(which sudo)" ]; then exit 1; fi -sudo apt-get update; -sudo apt-get install -y ${INSTALL_LIST}; -wget -q https://packages.microsoft.com/config/ubuntu/19.04/packages-microsoft-prod.deb -O /tmp/packages-microsoft-prod.deb; -sudo dpkg -i /tmp/packages-microsoft-prod.deb; -sudo apt-get update; -sudo apt-get install -y dotnet-sdk-3.0; +sudo apt-get update -qq; +sudo apt-get install -y -qq ${INSTALL_LIST}; +source ${BASE_DIR}/installers/apps/dotnet.sh; cd $HOME/Projects @@ -33,6 +30,10 @@ else snap install code docker firefox thunderbird insomnia discord slack spotify; # install polybar and alacritty + source ${BASE_DIR}/installers/apps/polybar.sh; + source ${BASE_DIR}/installers/apps/alacritty.sh; fi +source ${BASE_DIR}/installers/apps/vim.sh; + cd ${HOME} diff --git a/makefile b/makefile index 3091f24..444a969 100644 --- a/makefile +++ b/makefile @@ -5,6 +5,7 @@ build: ./tools docker build -t vdhsn/dotfiles:$${VERSION:-latest} \ + --no-cache \ --build-arg version=$${VERSION} \ --build-arg commit=$${COMMIT_SHA:-$${CIRCLE_SHA1}} \ --build-arg initiator=$${INITIATOR:-$${CIRCLE_USERNAME}} \ diff --git a/src/.config/compton/compton.conf b/src/.config/compton/compton.conf index 41ebb50..7268a6f 100644 --- a/src/.config/compton/compton.conf +++ b/src/.config/compton/compton.conf @@ -1,26 +1,14 @@ # basic configuration #backend = "glx"; #vsync = "opengl-swc"; -backend = "xrender"; -vsync = "opengl"; -# GLX backend: GLX buffer swap method we assume. -# Could be undefined (0), copy (1), exchange (2), 3-6, or buffer-age (-1). -# undefined is the slowest and the safest, and the default value. -# copy is fastest, but may fail on some drivers, -# 2-6 are gradually slower but safer (6 is still faster than 0). -# Usually, double buffer means 2, triple buffer means 3. -# buffer-age means auto-detect using GLX_EXT_buffer_age, supported by some drivers. -# Useless with --glx-use-copysubbuffermesa. -# Partially breaks --resize-damage. -# Defaults to undefined. -glx-swap-method = "2"; -#glx-swap-method = "3"; +#backend = "xrender"; +backend = "glx"; +vsync = true; +use-damage = true; glx-no-stencil = true; glx-copy-from-front = false; -xrender-sync = true; xrender-sync-fence = true; -paint-on-overlay = true; detect-rounded-corners = true; ################################# @@ -31,12 +19,6 @@ detect-rounded-corners = true; # Enabled client-side shadows on windows. shadow = true; -# Don't draw shadows on DND windows. -no-dnd-shadow = true; -# Avoid drawing shadows on dock/panel windows. -no-dock-shadow = true; -# Zero the part of the shadow's mask behind the window. Fix some weirdness with ARGB windows. -clear-shadow = true; # The blur radius for shadows. (default 12) shadow-radius = 5; # The left offset for shadows. (default -15) @@ -44,8 +26,7 @@ shadow-offset-x = -5; # The top offset for shadows. (default -15) shadow-offset-y = -5; # The translucency for shadows. (default .75) -shadow-opacity = 0.5; - +shadow-opacity = 0.75; # The shadow exclude options are helpful if you have shadows enabled. Due to the way compton draws its shadows, certain applications will have visual glitches # (most applications are fine, only apps that do weird things with xshapes or argb are affected). @@ -65,6 +46,7 @@ shadow-exclude = [ "name *= 'Visual'", "name *= 'Slack'", "name *= 'Insomnia'", + "name *= 'Zoom'", "class_g = 'Conky'", "class_g = 'Kupfer'", "class_g = 'Synapse'", @@ -82,23 +64,22 @@ shadow-ignore-shaped = false; # ################################# -menu-opacity = 1; inactive-opacity = 1; active-opacity = 1; frame-opacity = 1; -inactive-opacity-override = false; -alpha-step = 0.06; +inactive-opacity-override = true; # Dim inactive windows. (0.0 - 1.0) -inactive-dim = 0.2; +#inactive-dim = 0.1; # Do not let dimness adjust based on window opacity. -# inactive-dim-fixed = true; +#inactive-dim-fixed = true; # Blur background of transparent windows. Bad performance with X Render backend. GLX backend is preferred. -# blur-background = true; +#blur-background = true; +blur-background = false; # Blur background of opaque windows with transparent frames as well. # blur-background-frame = true; # Do not let blur radius adjust based on window opacity. -blur-background-fixed = false; +#blur-background-fixed = true; blur-background-exclude = [ "window_type = 'dock'", "window_type = 'desktop'" diff --git a/src/.config/i3/config b/src/.config/i3/config index d104cba..e66150b 100644 --- a/src/.config/i3/config +++ b/src/.config/i3/config @@ -8,37 +8,32 @@ font pango:DejaVu Sans Mono 12 -###################################################### +######################################### # STARTUP -####################################### +######################################### # set dpi settings -exec_always xrandr --dpi 165 - -# startup gnome -exec --no-startup-id /usr/lib/gnome-settings-daemon/gsd-xsettings -#exec --no-startup-id gnome-power-manager -exec --no-startup-id gnome-flashback - -# start compton for window composition -exec --no-startup-id compton --config ~/.config/compton/compton.conf -b +# for 4k +#exec_always xrandr --dpi 165 # start polybar exec_always --no-startup-id ~/.config/i3/polybar.sh & +# start picom for window composition +exec --no-startup-id picom --config ~/.config/compton/compton.conf -b -# start dunst for custom notification popups -exec --no-startup-id dunst -config ~/.config/dunst/dunstrc & +# set wallpaper +exec_always --no-startup-id nitrogen --head=0 --save --set-scaled ~/Pictures/Wallpapers/retro.jpg & -# startup pulse audio controls -exec pa-applet +# startup gnome +# exec --no-startup-id /usr/lib/gnome-settings-daemon/gsd-xsettings +# exec --no-startup-id gnome-power-manager +# exec --no-startup-id gnome-flashback -# set wallpaper -exec_always --no-startup-id nitrogen --head=0 --save --set-centered ~/Pictures/Wallpapers/landscapes/03886_paintedplains_3840x2160.jpg & -exec_always --no-startup-id nitrogen --head=1 --save --set-centered ~/Pictures/Wallpapers/landscapes/03886_paintedplains_3840x2160.jpg & -exec_always --no-startup-id nitrogen --head=2 --save --set-centered ~/Pictures/Wallpapers/landscapes/03886_paintedplains_3840x2160.jpg & +# start dunst for custom notification popups +# exec --no-startup-id dunst -config ~/.config/dunst/dunstrc & # save power -exec_always --no-startup-id powertop --auto-tune +# exec_always --no-startup-id powertop --auto-tune # connect to pritunl #exec --no-startup-id pritunl-client enable 65adf618f9dc44b9818b558d1b84bdba && pritunl-client start 65adf618f9dc44b9818b558d1b84bdba @@ -47,13 +42,23 @@ exec_always --no-startup-id powertop --auto-tune # BINDINGS ############################## -# audio controls -bindsym XF86AudioRaiseVolume exec amixer -q set Master 2%+ unmute -bindsym XF86AudioLowerVolume exec amixer -q set Master 2%- unmute -bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle +# screen shot (area) +# bindsym --release $mod+x exec --no-startup-id import /tmp/latest-screenshot.png -#Pause actually works as a play toggle for MPRIS interfaces. -bindsym XF86AudioPlay exec qdbus org.mpris.clementine /Player Pause +# Pulse Audio controls +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 0 +5% #increase sound volume +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 0 -5% #decrease sound volume +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle # mute sound + +# Media player controls +bindsym XF86AudioPlay exec playerctl play-pause +bindsym XF86AudioPause exec playerctl pause +bindsym XF86AudioNext exec playerctl next +bindsym XF86AudioPrev exec playerctl previous + +# Backlight +bindsym XF86MonBrightnessUp exec light -A 10 # increase screen brightness +bindsym XF86MonBrightnessDown exec light -U 10 # decrease screen brightness # start a terminal bindsym Mod1+Return exec terminator @@ -61,7 +66,8 @@ bindsym Mod1+Return exec terminator bindsym Mod1+Shift+i exec insomnia # start chrome with correct DPI settings -bindsym Mod1+Shift+Return exec google-chrome-stable --force-device-scale-factor=1.65 %U +# bindsym Mod1+Shift+Return exec google-chrome-stable --force-device-scale-factor=1.65 %U +bindsym Mod1+Shift+Return exec firefox # Sets up 2 external displays side by side, with the laptop display on the far right bindsym Mod1+Shift+f exec xrandr --output DVI-I-2-1 --auto --left-of DVI-I-3-2 && sleep 1 && xrandr --output DVI-I-3-2 --auto --left-of DP-0 && sleep 1 && xrandr --output DP-0 --auto --primary --preferred @@ -69,16 +75,11 @@ bindsym Mod1+Shift+g exec xrandr --output DVI-I-2-2 --auto --left-of DVI-I-1-1 & # disconnects the 2 external monitors bindsym Mod1+Shift+Ctrl+g exec xrandr --output DVI-I-3-2 --off && xrandr --output DVI-I-2-1 --off - bindsym Mod1+Shift+x move workspace to output right # turn off laptop monitor bindsym Mod1+Shift+~ exec xrandr --output DP-0 --off -# start/stop pritunl -bindsym Mod1+Shift+v exec pritunl-client start 65adf618f9dc44b9818b558d1b84bdba -bindsym Mod1+Shift+Ctrl+v exec pritunl-client stop 65adf618f9dc44b9818b558d1b84bdba - # There also is the (new) i3-dmenu-desktop which only displays applications # shipping a .desktop file. It is a wrapper around dmenu, so you need that installed. bindsym Mod1+d exec --no-startup-id i3-dmenu-desktop @@ -88,7 +89,7 @@ bindsym Mod1+Shift+c reload # restart i3 inplace (preserves your layout/session, can be used to upgrade i3) bindsym Mod1+Shift+r restart # exit i3 (logs you out of your X session) -bindsym Mod1+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'" +bindsym Mod1+Shift+e exec "i3-nagbar -t warning -m 'Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'" # move the currently focused window to the scratchpad bindsym Mod1+Shift+minus move scratchpad @@ -125,7 +126,6 @@ bindsym Mod1+$down focus down bindsym Mod1+$up focus up bindsym Mod1+$right focus right - # alternatively, you can use the cursor keys: bindsym Mod1+Left focus left bindsym Mod1+Down focus down diff --git a/src/.config/i3/polybar.sh b/src/.config/i3/polybar.sh old mode 100644 new mode 100755 index acdb55e..ceab9c5 --- a/src/.config/i3/polybar.sh +++ b/src/.config/i3/polybar.sh @@ -2,6 +2,6 @@ killall -q polybar while pgrep -x polybar >/dev/null; do sleep 1; done -MONITOR=DP-0 polybar bar1 & -MONITOR=DVI-I-1-1 polybar bar1 & -MONITOR=DVI-I-2-2 polybar bar1 & +# MONITOR=DP-0 polybar 4k-bottom & +MONITOR=eDP-1 polybar 1080p-bottom & +MONITOR=eDP-1 polybar 1080p-top & diff --git a/src/.config/nitrogen/bg-saved.cfg b/src/.config/nitrogen/bg-saved.cfg index 3e7ace8..a58583e 100644 --- a/src/.config/nitrogen/bg-saved.cfg +++ b/src/.config/nitrogen/bg-saved.cfg @@ -1,6 +1,6 @@ [xin_0] -file=~/.config/nitrogen/painted_plains_3840x2160.jpg -mode=2 +file=/home/adam/Pictures/Wallpapers/retro.jpg +mode=0 bgcolor=#000000 [xin_1] diff --git a/src/.config/polybar/config b/src/.config/polybar/config index ebc9dab..97f94eb 100644 --- a/src/.config/polybar/config +++ b/src/.config/polybar/config @@ -8,25 +8,21 @@ ;===================================================== [colors] -;background = ${xrdb:color0:#222} background = #222 background-alt = #444 -;foreground = ${xrdb:color7:#222} foreground = #dfdfdf foreground-alt = #555 primary = #ffb52a secondary = #e60053 alert = #bd2c40 +success = #55aa55 +warning = #ffda17 -[bar/bar1] -;remove padding around bar -;override-redirect = true +[bar/1080p-top] monitor = ${env:MONITOR:DP-0} width = 100% -height = 50 +height =25 -;offset-x = 1% -;offset-y = 0% - 10 radius = 0 fixed-center = false @@ -36,7 +32,7 @@ foreground = ${colors.foreground} line-size = 3 line-color = #f00 -border-size = 5 +border-size = 0 border-color = #00000000 padding-left = 3 @@ -45,34 +41,80 @@ padding-right = 3 module-margin-left = 1 module-margin-right = 1 -font-0 = "Ubuntu Mono derivative Powerline:style=Regular:pixelsize=16:1" -font-1 = "Symbola:size=18:antialias=true" -font-2 = "OpenSymbol:style=bold:size=20;antialias=false" -font-3 = "nanumbarungothic:style=bold:size=20;antialias=false" +font-0 = "Ubuntu Mono derivative Powerline:style=Regular:pixelsize=12:1" +font-1 = "Symbola:size=16:antialias=true" +font-2 = "PragmataPro Liga:style=Regular:pixelsize=12:1" -modules-left = i3 xwindow -modules-center = spotify mpd -modules-right = polypomo volume filesystem temperature cpu memory wlan eth battery date powermenu +modules-left = powermenu i3 xwindow +modules-center = +modules-right = polypomo wlan eth battery date -bottom = true +bottom = false tray-position = right tray-padding = 4 -tray-transparent = false -tray-maxsize = 32 -;tray-background = #0063ff +tray-transparent = true +tray-maxsize = 16 cursor-click = pointer cursor-scroll = ns-resize -dpi-y = 125 -dpi-x = 125 +dpi-y = 100 +dpi-x = 100 + + +[bar/1080p-bottom] +;remove padding around bar +;override-redirect = true +monitor = ${env:MONITOR:DP-0} +width = 100% +height = 30 + +radius = 0 +fixed-center = false + +background = ${colors.background} +foreground = ${colors.foreground} + +line-size = 3 +line-color = #f00 + +border-size = 0 +border-color = #00000000 + +padding-left = 3 +padding-right = 3 + +module-margin-left = 1 +module-margin-right = 1 + +font-0 = "Ubuntu Mono derivative Powerline:style=Regular:pixelsize=12:1" +font-1 = "Symbola:size=16:antialias=true" +font-2 = "PragmataPro Liga:style=Regular:pixelsize=12:1" + +modules-left = spotify +modules-center = +modules-right = volume backlight filesystem temperature cpu memory keyboard + +bottom = true +; tray-position = right +; tray-padding = 4 +; tray-transparent = true +; tray-maxsize = 16 -[bar/bar2] +cursor-click = pointer +cursor-scroll = ns-resize +dpi-y = 100 +dpi-x = 100 + +[bar/4k-bottom] +;remove padding around bar +;override-redirect = true monitor = ${env:MONITOR:DP-0} width = 100% -height = 50 +; 4k +height = 50 ;offset-x = 1% -;offset-y = 1% +;offset-y = 0% - 10 radius = 0 fixed-center = false @@ -91,30 +133,31 @@ padding-right = 3 module-margin-left = 1 module-margin-right = 1 -font-0 = "Ubuntu Mono derivative Powerline:style=Regular:pixelsize=20;1" -font-1 = "Symbola:size=25:antialias=true" -font-2 = "OpenSymbol:style=bold:size=26;antialias=false" -font-3 = "nanumbarungothic:style=bold:size=26;antialias=false" +font-0 = "Ubuntu Mono derivative Powerline:style=Regular:pixelsize=16:1" +font-1 = "Symbola:size=18:antialias=true" +font-2 = "PragmataPro Liga:style=Regular:pixelsize=12:1" modules-left = i3 xwindow -modules-center = mpd -modules-right = xkeyboard volume filesystem temperature cpu memory wlan eth battery date powermenu +modules-center = spotify mpd +modules-right = volume polypomo filesystem temperature cpu memory wlan eth battery date powermenu -bottom = false -top = true +bottom = true tray-position = right tray-padding = 4 tray-transparent = false +tray-maxsize = 32 ;tray-background = #0063ff cursor-click = pointer cursor-scroll = ns-resize +dpi-y = 125 +dpi-x = 125 [module/xwindow] type = internal/xwindow -label = %title:0:30:...% +label = %title:0:60:...% -[module/xkeyboard] +[module/keyboard] type = internal/xkeyboard blacklist-0 = num lock @@ -207,23 +250,37 @@ icon-next =  label-song-maxlen = 25 label-song-ellipsis = true -; [module/xbacklight] -; type = internal/xbacklight -; -; output = DP-0 +[module/backlight] +; Use the following command to list available cards: +; $ ls -1 /sys/class/backlight/ +type = internal/backlight + +; Default: the monitor defined for the running bar +; output = eDP-1 +card = intel_backlight + +enable-scroll = true + +; output = eDP-1 ; format =