Add maim and formalize kutu config
This commit is contained in:
+4
-2
@@ -1,7 +1,9 @@
|
||||
run "bash @src@/startup.sh"
|
||||
|
||||
bind_key 23, true, "firefox"
|
||||
bind_key 24, true, :kill_window
|
||||
bind_key 25, true, "kitty"
|
||||
bind_key 26, true, "bash /home/me/dotfiles/scripts/power.sh"
|
||||
bind_key 26, true, "bash @src@/power.sh"
|
||||
|
||||
bind_key 123, false, %q(
|
||||
pactl set-sink-volume @DEFAULT_SINK@ +5%;
|
||||
@@ -44,7 +46,7 @@ bind_key 54, true, 'kitty -e fish -c "y"'
|
||||
bind_key 53, true, 'kitty -e fish -c "editor"'
|
||||
bind_key 41, true, 'kitty -e fish -c "btop"'
|
||||
|
||||
bind_key 40, true, "bash /home/me/dotfiles/scripts/run.sh"
|
||||
bind_key 40, true, "bash @src@/run.sh"
|
||||
|
||||
bind_key 56, true, :add_workspace
|
||||
bind_key 57, true, :delete_workspace
|
||||
|
||||
+10
-2
@@ -1,5 +1,13 @@
|
||||
{ ... }:
|
||||
{ pkgs, ... }:
|
||||
|
||||
let
|
||||
script = pkgs.substitute {
|
||||
src = ./config.rb;
|
||||
substitutions = [
|
||||
"--replace-fail" "@src@" "${./scripts}"
|
||||
];
|
||||
};
|
||||
in
|
||||
{
|
||||
home.file.".config/kutu/config.rb".source = ./config.rb;
|
||||
home.file.".config/kutu/config.rb".source = script;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [[ "$(xset q | awk '/timeout:/ {print $2}')" == "0" ]]; then
|
||||
xset s on
|
||||
xset +dpms
|
||||
else
|
||||
xset s off
|
||||
xset -dpms
|
||||
fi
|
||||
@@ -0,0 +1,42 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
opts=" Lock
|
||||
Suspend
|
||||
Shutdown
|
||||
Reboot
|
||||
Hibernate
|
||||
Stop KutuWM"
|
||||
|
||||
sel=$(printf "%s\n" "$opts" | dmenu -i -p "Select Power Option:" \
|
||||
-nf '#e0af68' -nb '#1f2335' -sb '#f7768e' -sf '#1a1b26' -fn 'AgaveNerdFont-16')
|
||||
|
||||
[ -z "$sel" ] && exit 0
|
||||
|
||||
case "$sel" in
|
||||
*Shutdown*)
|
||||
confirm=$(printf "No\nYes" | dmenu -i -p "Are you sure you want to shutdown? :" \
|
||||
-nf '#e0af68' -nb '#1f2335' -sb '#f7768e' -sf '#1a1b26' -fn 'AgaveNerdFont-16')
|
||||
[ "$confirm" = "Yes" ] && exec shutdown -h now
|
||||
;;
|
||||
*Reboot*)
|
||||
confirm=$(printf "No\nYes" | dmenu -i -p "Are you sure you want to reboot? :" \
|
||||
-nf '#e0af68' -nb '#1f2335' -sb '#f7768e' -sf '#1a1b26' -fn 'HurmitNerdFont-16')
|
||||
[ "$confirm" = "Yes" ] && exec reboot
|
||||
;;
|
||||
*Hibernate*)
|
||||
confirm=$(printf "No\nYes" | dmenu -i -p "Are you sure you want to hibernate? :" \
|
||||
-nf '#e0af68' -nb '#1f2335' -sb '#f7768e' -sf '#1a1b26' -fn 'AgaveNerdFont-16')
|
||||
[ "$confirm" = "Yes" ] && exec systemctl hibernate
|
||||
;;
|
||||
*Stop\ KutuWM*)
|
||||
exec kutu-run.rb stop
|
||||
;;
|
||||
*Suspend*)
|
||||
exec systemctl suspend
|
||||
;;
|
||||
*Lock*)
|
||||
~/dotfiles/scripts/lock.sh &
|
||||
;;
|
||||
esac
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
choice=$(
|
||||
(
|
||||
printf "%s\n" prism
|
||||
compgen -c
|
||||
) |
|
||||
grep -v -E '^(if|fi|case|esac|for|done|while|until|select|function|return|continue|break|time|exec|source|alias|builtin|read|export|unset|local|set|declare|typeset|:|\.|\[|coproc|l|ll|ls|then|else|elif|do|in|\{|\}|!|\[\[|\]\]|_.*|compgen)$' |
|
||||
sort |
|
||||
dmenu -i -p "Enter command " \
|
||||
-nf '#4abaaf' -nb '#1f2335' -sb '#7aa2f7' -sf '#102030' -fn 'AgaveNerdFont-16'
|
||||
)
|
||||
|
||||
[ -z "$choice" ] && exit 0
|
||||
|
||||
fish -c "$choice" >/dev/null 2>&1 &
|
||||
disown
|
||||
@@ -0,0 +1,5 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
xsetroot -cursor_name left_ptr
|
||||
|
||||
setxkbmap us
|
||||
Reference in New Issue
Block a user