small tweaks for the home server; improved monitor detection; i3 "game" workspace; local plugin detection improvement; help docs; etc
This commit is contained in:
parent
37b562b5c9
commit
cebedf3e07
@ -1,6 +1,19 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
source ${0:a:h}/xorg.zsh
|
source ${0:a:h}/xorg.zsh
|
||||||
|
|
||||||
|
case $MONITOR_CONFIGURATION in
|
||||||
|
home )
|
||||||
|
;;
|
||||||
|
unknown )
|
||||||
|
echo 'unknown state; using default configuration to prevent monitor issues'
|
||||||
|
xrandr --output $(xrandr | grep ' connected' | awk '{print $1;}') --primary
|
||||||
|
scwrypts desktop i3 set background -- $(scwrypts -n get theme).jpg
|
||||||
|
$DOTWRYN/bin/polybar
|
||||||
|
scwrypts desktop play sound -- login
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
USE_SMOL=false
|
USE_SMOL=false
|
||||||
xrandr -q | grep $XRANDR_OUTPUT__smol | grep -v 'disconnected' && {
|
xrandr -q | grep $XRANDR_OUTPUT__smol | grep -v 'disconnected' && {
|
||||||
xrandr -q | grep $XRANDR_OUTPUT__smol | grep -qv primary && {
|
xrandr -q | grep $XRANDR_OUTPUT__smol | grep -qv primary && {
|
||||||
|
@ -25,6 +25,16 @@ XRANDR_ARGS__smol__1080p=(--output $XRANDR_OUTPUT__smol --mode $XRANDR_RESOLUTIO
|
|||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
MONITOR_CONFIGURATION=unknown
|
||||||
|
|
||||||
|
: \
|
||||||
|
&& xrandr --query | grep -q "^$XRANDR_OUTPUT__office connected" \
|
||||||
|
&& xrandr --query | grep -q "^$XRANDR_OUTPUT__livingroom connected" \
|
||||||
|
&& MONITOR_CONFIGURATION=home \
|
||||||
|
;
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
XRANDR_SET() {
|
XRANDR_SET() {
|
||||||
local ERRORS=0
|
local ERRORS=0
|
||||||
|
|
||||||
|
@ -5,9 +5,17 @@
|
|||||||
# e.g. "$HOME/Projects/GitHub" will be called "GitHub" in the CLI
|
# e.g. "$HOME/Projects/GitHub" will be called "GitHub" in the CLI
|
||||||
#
|
#
|
||||||
# directories must be fully-qualified
|
# directories must be fully-qualified
|
||||||
CA__DIRS=(
|
|
||||||
$([ -d "$HOME/Projects" ] && find "$HOME/Projects" -mindepth 1 -maxdepth 1 -type d | sed 's/\/$//')
|
CA__DIRS=()
|
||||||
)
|
|
||||||
|
for __CA_DIR_LOOKUP in \
|
||||||
|
"$HOME/Projects" \
|
||||||
|
;
|
||||||
|
do
|
||||||
|
__CA_DIR_LOOKUP="$(readlink -f -- "$__CA_DIR_LOOKUP")"
|
||||||
|
[ "$__CA_DIR_LOOKUP" ] && [ -d "$__CA_DIR_LOOKUP" ] && CA__DIRS+=($(find "$__CA_DIR_LOOKUP" -mindepth 1 -maxdepth 1 -type d | sed 's/\/$//'))
|
||||||
|
done
|
||||||
|
unset __CA_DIR_LOOKUP
|
||||||
|
|
||||||
# additional cloning targets; MUST END IN ':' or '/'
|
# additional cloning targets; MUST END IN ':' or '/'
|
||||||
# e.g. 'git@my.githost.com:' or 'git@github.com:w0ryn/'
|
# e.g. 'git@my.githost.com:' or 'git@github.com:w0ryn/'
|
||||||
|
@ -87,7 +87,7 @@ bindsym $mod+7 workspace number "7"; exec --no-startup-id polybar-msg cmd show
|
|||||||
bindsym $mod+8 workspace number "8"; exec --no-startup-id polybar-msg cmd hide
|
bindsym $mod+8 workspace number "8"; exec --no-startup-id polybar-msg cmd hide
|
||||||
bindsym $mod+9 workspace number "9"; exec --no-startup-id polybar-msg cmd show
|
bindsym $mod+9 workspace number "9"; exec --no-startup-id polybar-msg cmd show
|
||||||
bindsym $mod+0 workspace number "0"; exec --no-startup-id polybar-msg cmd hide
|
bindsym $mod+0 workspace number "0"; exec --no-startup-id polybar-msg cmd hide
|
||||||
|
bindsym $mod+g workspace "🎮"; exec --no-startup-id polybar-msg cmd hide
|
||||||
|
|
||||||
bindsym $mod+Shift+1 move container to workspace number "1"
|
bindsym $mod+Shift+1 move container to workspace number "1"
|
||||||
bindsym $mod+Shift+2 move container to workspace number "2"
|
bindsym $mod+Shift+2 move container to workspace number "2"
|
||||||
@ -99,6 +99,7 @@ bindsym $mod+Shift+7 move container to workspace number "7"
|
|||||||
bindsym $mod+Shift+8 move container to workspace number "8"
|
bindsym $mod+Shift+8 move container to workspace number "8"
|
||||||
bindsym $mod+Shift+9 move container to workspace number "9"
|
bindsym $mod+Shift+9 move container to workspace number "9"
|
||||||
bindsym $mod+Shift+0 move container to workspace number "0"
|
bindsym $mod+Shift+0 move container to workspace number "0"
|
||||||
|
bindsym $mod+Shift+g move container to workspace "🎮"
|
||||||
|
|
||||||
mode "resize" {
|
mode "resize" {
|
||||||
bindsym h resize grow width 10 px or 10 ppt
|
bindsym h resize grow width 10 px or 10 ppt
|
||||||
@ -121,7 +122,7 @@ floating_modifier $mod
|
|||||||
bindsym $mod+Shift+Tab move scratchpad
|
bindsym $mod+Shift+Tab move scratchpad
|
||||||
bindsym $mod+Tab scratchpad show
|
bindsym $mod+Tab scratchpad show
|
||||||
|
|
||||||
set $GAMES_CLIENT_CLASSES ^(Steam)|(dolphin-emu)|(Visualboyadvance-m)|(steam_app_.*)$
|
set $GAMES_CLIENT_CLASSES ^(steam)|(dolphin-emu)|(Visualboyadvance-m)|(steam_app_.*)$
|
||||||
bindsym $mod+Shift+x [class=$GAMES_CLIENT_CLASSES] scratchpad show
|
bindsym $mod+Shift+x [class=$GAMES_CLIENT_CLASSES] scratchpad show
|
||||||
|
|
||||||
set $TERMINAL_EMULATOR_CLASSES ^(Alacritty)$
|
set $TERMINAL_EMULATOR_CLASSES ^(Alacritty)$
|
||||||
@ -141,6 +142,9 @@ for_window [window_type="dialog"] floating enable
|
|||||||
for_window [window_type="menu"] floating enable
|
for_window [window_type="menu"] floating enable
|
||||||
for_window [class="[xX]fce4-notifyd"] border pixel 0
|
for_window [class="[xX]fce4-notifyd"] border pixel 0
|
||||||
|
|
||||||
|
# gaming stuff
|
||||||
|
for_window [class="^steam_app_"] move container to workspace "🎮"
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
## i3 Settings #################################################################
|
## i3 Settings #################################################################
|
||||||
################################################################################
|
################################################################################
|
||||||
|
@ -26,7 +26,7 @@ separator = " "
|
|||||||
separator-foreground = ${colors.disabled}
|
separator-foreground = ${colors.disabled}
|
||||||
|
|
||||||
font-0 = Monaspace Krypton:style=Bold
|
font-0 = Monaspace Krypton:style=Bold
|
||||||
font-1 = Noto Color Emoji:style=Regular
|
font-1 = Noto Color Emoji:style=Regular:scale=9;
|
||||||
font-2 = Symbols Nerd Font:style=Regular
|
font-2 = Symbols Nerd Font:style=Regular
|
||||||
font-3 = DejaVu Sans:style=Bold
|
font-3 = DejaVu Sans:style=Bold
|
||||||
font-4 = Font Awesome 6 Free
|
font-4 = Font Awesome 6 Free
|
||||||
|
@ -4,10 +4,11 @@ use system/desktop/notify
|
|||||||
DEPENDENCIES+=(i3-msg xdotool xrandr)
|
DEPENDENCIES+=(i3-msg xdotool xrandr)
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
USAGE="
|
USAGE__description="
|
||||||
usage: <path-executable> [client-class] [...options...]
|
usage: <path-executable> [client-class] [...options...]
|
||||||
|
"
|
||||||
|
|
||||||
options
|
USAGE__options="
|
||||||
-c, --client <string> if different from the executable name, xprop CLIENT_CLASS
|
-c, --client <string> if different from the executable name, xprop CLIENT_CLASS
|
||||||
|
|
||||||
-s, --scale <value> (default: 0.8 or 0.5 if screen width >3000px)
|
-s, --scale <value> (default: 0.8 or 0.5 if screen width >3000px)
|
||||||
@ -21,7 +22,9 @@ USAGE="
|
|||||||
--has-statusbar-icon (default: false) use if program has a statusbar icon
|
--has-statusbar-icon (default: false) use if program has a statusbar icon
|
||||||
|
|
||||||
-h, --help print this message and exit
|
-h, --help print this message and exit
|
||||||
|
"
|
||||||
|
|
||||||
|
USAGE__description="
|
||||||
Makes it easy to bind appications to key shortcuts without having to
|
Makes it easy to bind appications to key shortcuts without having to
|
||||||
spin up redundant instances or cycle through the scratchpad queue.
|
spin up redundant instances or cycle through the scratchpad queue.
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
ZSH_PLUGINS+=($(
|
ZSH_PLUGINS+=($(
|
||||||
find "$HOME/.local/zsh" -type f 2>/dev/null
|
find "$(readlink -f -- "$HOME/.local/zsh")" -type f 2>/dev/null
|
||||||
))
|
))
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
Loading…
Reference in New Issue
Block a user