From 6e18bfed698a34fe5d408312def1bc2750f5e5a6 Mon Sep 17 00:00:00 2001 From: Daniel Flanagan Date: Thu, 8 Nov 2018 10:49:00 -0600 Subject: [PATCH] Work on wallpaper scripts --- de/bspwm/fehbg | 14 ++++++++++++++ de/sway/dm_entry | 4 ++-- de/sxhkd/sxhkdrc | 18 +++++++++--------- scripts/bin/setbg | 6 +++++- scripts/bin/workdock | 5 ++++- setup | 3 ++- shell/bash/aliases | 1 - 7 files changed, 36 insertions(+), 15 deletions(-) create mode 100755 de/bspwm/fehbg diff --git a/de/bspwm/fehbg b/de/bspwm/fehbg new file mode 100755 index 0000000..bce8405 --- /dev/null +++ b/de/bspwm/fehbg @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +feh --no-fehbg --bg-fill \ + "${HOME}/.wallpaper" \ + "${HOME}/.wallpaper2" \ + "${HOME}/.wallpaper3" \ + "${HOME}/.wallpaper4" \ + "${HOME}/.wallpaper5" \ + "${HOME}/.wallpaper6" \ + "${HOME}/.wallpaper7" \ + "${HOME}/.wallpaper8" \ + "${HOME}/.wallpaper9" \ + "${HOME}/.wallpaper_last" \ + 2>/dev/null diff --git a/de/sway/dm_entry b/de/sway/dm_entry index db4aca3..5f1511f 100644 --- a/de/sway/dm_entry +++ b/de/sway/dm_entry @@ -1,5 +1,5 @@ [Desktop Entry] -Name=Sway -Comment=SirCmpwn's Wayland window manager +Name=sway-lytedev +Comment=SirCmpwn's Wayland window manager with lytedev's config Exec=sway-lytedev Type=Application diff --git a/de/sxhkd/sxhkdrc b/de/sxhkd/sxhkdrc index 855df10..aa0a187 100755 --- a/de/sxhkd/sxhkdrc +++ b/de/sxhkd/sxhkdrc @@ -33,6 +33,7 @@ super + {_,shift + }{h,j,k,l} bspc node -{f,s} {west,south,north,east} # swap previous/next desktops + super + bracket{left,right} bspc desktop -f {prev,next} @@ -72,6 +73,7 @@ super + {_,shift + }{1-9,0} ~button1 bspc node -f pointed +# set the current node's dimensions to 1920x1080 (for streaming) super + shift + alt + ctrl + s wres1080 @@ -131,17 +133,9 @@ super + ctrl + alt + shift + space super + ctrl + alt + space bspc config -d focused bottom_padding 200; bspc config -d focused top_padding 200; bspc config -d focused left_padding 400; bspc config -d focused right_padding 400 - - super + alt + minus bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) - 5) -# wm-independant shortcuts - -# spawn a transparent node -super + alt + t - urxvtc && compton-trans -c -o 0 - # rotate the current node super + r bspc node -R 90 @@ -150,6 +144,12 @@ super + r super + shift + b bspc node -B +# wm-independant shortcuts + +# spawn a transparent node +super + alt + t + urxvtc && compton-trans -c -o 0 + # make current node transparent super + t compton-trans -c -o 0 @@ -168,7 +168,7 @@ super + Return # spawn a floating terminal super + shift + Return - bspc rule -a '*' -o state=floating && urxvtc --dimensions 80x24 + bspc rule -a '*' -o state=floating && urxvtc # spawn the app launcher super + space diff --git a/scripts/bin/setbg b/scripts/bin/setbg index 2920902..ada419d 100755 --- a/scripts/bin/setbg +++ b/scripts/bin/setbg @@ -1,3 +1,7 @@ #!/usr/bin/env bash -feh --bg-fill "$@" +index="${2}" +wp_file="${HOME}/.wallpaper${index}" +rm -f "${wp_file}" +ln -s "${1}" "${wp_file}" +"${HOME}/.fehbg" diff --git a/scripts/bin/workdock b/scripts/bin/workdock index 1bc74bc..29d155e 100755 --- a/scripts/bin/workdock +++ b/scripts/bin/workdock @@ -1,3 +1,6 @@ #!/usr/bin/env bash -"$DOTFILES_PATH/de/x/loadresources" lodpi && autorandr --change && sleep 1 && restartbar +"${DOTFILES_PATH}/de/x/loadresources" lodpi +autorandr --change +restartbar +"${HOME}/.fehbg" diff --git a/setup b/setup index ef97074..dc65057 100755 --- a/setup +++ b/setup @@ -7,8 +7,9 @@ source "${dfp}/scripts/setup_helpers.bash" links=( # desktop environment files - "$dfp/de/sway/config" "$XDG_CONFIG_HOME/sway/config" "$dfp/de/bspwm/bspwmrc" "$XDG_CONFIG_HOME/bspwm/bspwmrc" + "$dfp/de/bspwm/fehbg" "$HOME/.fehbg" + "$dfp/de/sway/config" "$XDG_CONFIG_HOME/sway/config" "$dfp/de/sxhkd/sxhkdrc" "$XDG_CONFIG_HOME/sxhkd/sxhkdrc" "$dfp/de/x/resources" "$HOME/.Xresources" "$dfp/de/x/initrc" "$HOME/.xinitrc" diff --git a/shell/bash/aliases b/shell/bash/aliases index 1b2ba56..e3013b8 100644 --- a/shell/bash/aliases +++ b/shell/bash/aliases @@ -69,7 +69,6 @@ alias gl="git log --graph --pretty=oneline --abbrev-commit --decorate" # misc aliases alias qute="qutebrowser --backend webengine" alias p="ping 8.8.8.8" -alias setbg="feh --bg-fill" alias C="clear && clear" alias keyrepeat="xset r rate 250 80" alias r="ranger"