Compare commits

...

4 Commits

4 changed files with 55 additions and 4 deletions

View File

@@ -3,10 +3,19 @@
wlr-randr --output DP-1 --mode 3840x2160 --scale 2
wlr-randr --output HDMI-A-1 --mode 3840x2160 --scale 2 --left-of DP-1
foot --server &
argenctl config set label-mode modifier
# Terminal
argenctl binding set normal Super Return sh "kitty --single-instance --instance-group default"
#argenctl binding set normal Super Return sh "kitty --single-instance --instance-group default"
argenctl binding set normal Super Return sh "
if [ -e ~/.lightmode ]; then
exec footclient -o initial-color-theme=light
else
exec footclient -o initial-color-theme=dark
fi
"
# Reload config
argenctl binding set normal Super+Shift R exec "$0"
@@ -21,8 +30,8 @@ argenctl binding set normal Super K window focus prev
argenctl binding set normal Super+Shift J window swap next
argenctl binding set normal Super+Shift K window swap prev
argenctl binding set normal Super F window float
argenctl binding set normal Super+Shift F window fullscreen
argenctl binding set normal Super F window fullscreen
argenctl binding set normal Super W window float
argenctl binding set normal Super+Shift C window close
argenctl binding set normal Super+Shift X window detach
@@ -34,6 +43,8 @@ argenctl binding set normal Super+Shift Period window send next
argenctl binding set normal Super+Shift Comma window send prev
# Layout
argenctl binding set normal Super M layout switch monocle
argenctl binding set normal Super S layout switch stacktile
argenctl binding set normal Super H layout set primary-ratio -0.05
argenctl binding set normal Super L layout set primary-ratio +0.05
argenctl binding set normal Super+Control K layout set secondary-ratio -0.05
@@ -101,7 +112,7 @@ VOL_TOGGLE='wpctl set-mute @DEFAULT_SINK@ toggle'
for mode in normal locked; do
argenctl binding set $mode Super Bracketleft sh "$VOL_DEC"
argenctl binding set $mode Super Bracketright sh "$VOL_INC"
argenctl binding set $mode Super M sh "$VOL_TOGGLE"
argenctl binding set $mode Super+Shift M sh "$VOL_TOGGLE"
argenctl binding set $mode None XF86AudioLowerVolume sh "$VOL_DEC"
argenctl binding set $mode None XF86AudioRaiseVolume sh "$VOL_INC"
argenctl binding set $mode None XF86AudioMute sh "$VOL_TOGGLE"
@@ -141,5 +152,7 @@ for num in 1 2 3 4 5 6 7 8 9; do
"
done
argenctl binding set normal Super+Shift S exec ~/.config/argen/session.sh
# Rules
argenctl rule add float --app-id "my-app"

29
argen/.config/argen/session.sh Executable file
View File

@@ -0,0 +1,29 @@
#!/bin/sh
set -eu
id=$(for name in $(ls ~/.config/argen/sessions/*.sh); do echo $(basename "${name%.sh}"); done | fuzzel -d -p'session> ')
if argenctl context list | grep "^${id}\$"; then
argenctl context switch "${id}"
exit
fi
argenctl context new "$id"
first=$(argenctl output list --json | jq -r 'min_by(80000 * .y + .x).id')
length=$(argenctl output list --json | jq -r 'length')
for n in $(seq $length); do
current=$(argenctl output list --json | jq -r '.[] | select(.focused).id')
if [ "$current" = "$first" ]; then
break
fi
argenctl output focus next
done
if [ -e ~/.lightmode ]; then
THEME=light
else
THEME=dark
fi
export TERMINAL="footclient -o initial-color-theme=$THEME"
exec sh ~/.config/argen/sessions/"${id}.sh"

View File

@@ -0,0 +1,3 @@
argenctl output focus next
argenctl sh "$TERMINAL -D ~/dotfiles kak -s dotfiles"

View File

@@ -0,0 +1,6 @@
argenctl exec librewolf
sleep 1
argenctl output focus next
argenctl exec qutebrowser