daily configuration optimization
Fix - airplay: systemd wantedBy target - fcitx5: remove redundant systemd service Remove - move scripts into configuration Style - ghostty: add more transparency to background Add - zellij
This commit is contained in:
parent
44c152fdc9
commit
9c9acc3494
24 changed files with 941 additions and 856 deletions
|
|
@ -56,4 +56,4 @@ vim.g.clipboard = {
|
|||
-- (instead of interacting with the "+" and/or "*" registers explicitly):
|
||||
vim.opt.clipboard = "unnamedplus"
|
||||
|
||||
vim.g.gruvbox_material_transparent_background = 2
|
||||
vim.opt.spelllang = { "en", "cjk" }
|
||||
|
|
|
|||
|
|
@ -1,22 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
SERVICE="gamemode"
|
||||
|
||||
if [ "$1" = "toggle" ]; then
|
||||
if systemctl --user is-active --quiet "$SERVICE"; then
|
||||
systemctl --user stop "$SERVICE"
|
||||
notify-send " Gamemode" "off" >/dev/null 2>&1
|
||||
else
|
||||
systemctl --user start "$SERVICE"
|
||||
notify-send " Gamemode" "on" >/dev/null 2>&1
|
||||
fi
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if ! systemctl --user is-active --quiet "$SERVICE"; then
|
||||
echo "{\"text\": \"inactive\", \"tooltip\": \"gamemoded is inactive\", \"alt\": \"inactive\", \"class\": \"inactive\"}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "{\"text\": \"active\", \"tooltip\": \"gamemoded is running\", \"alt\": \"active\", \"class\": \"active\"}"
|
||||
exit 0
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
get_icons() {
|
||||
local session_name="$1"
|
||||
local result=""
|
||||
|
||||
local panes=($(tmux list-panes -t "$session_name" -F '#{pane_current_command}'))
|
||||
|
||||
for i in "${panes[@]}"; do
|
||||
case "$i" in
|
||||
nvim) result+=" " ;;
|
||||
zsh | *) result+=" " ;;
|
||||
esac
|
||||
done
|
||||
|
||||
echo "$result"
|
||||
}
|
||||
|
||||
if (($# != 1)); then
|
||||
echo "Usage: $0 <session-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
get_icons "$1"
|
||||
|
|
@ -1,33 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
#Taken from JaKoolit's dotfiles
|
||||
|
||||
bar="▁▂▃▄▅▆▇█"
|
||||
dict="s/;//g"
|
||||
|
||||
bar_length=${#bar}
|
||||
|
||||
for ((i = 0; i < bar_length; i++)); do
|
||||
dict+=";s/$i/${bar:$i:1}/g"
|
||||
done
|
||||
|
||||
config_file="/tmp/bar_cava_config"
|
||||
cat >"$config_file" <<EOF
|
||||
[general]
|
||||
bars = 10
|
||||
|
||||
[input]
|
||||
method = pulse
|
||||
source = auto
|
||||
|
||||
[output]
|
||||
method = raw
|
||||
raw_target = /dev/stdout
|
||||
data_format = ascii
|
||||
channels = mono
|
||||
ascii_max_range = 7
|
||||
EOF
|
||||
|
||||
pkill -f "cava -p $config_file"
|
||||
|
||||
cava -p "$config_file" | sed -u "$dict"
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
INTERFACE="wg0"
|
||||
|
||||
if [ "$1" = "toggle" ]; then
|
||||
if ip link show "$INTERFACE" >/dev/null 2>&1; then
|
||||
pkexec systemctl stop wg-quick-wg0.service
|
||||
else
|
||||
pkexec systemctl start wg-quick-wg0.service
|
||||
fi
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if ! ip link show "$INTERFACE" >/dev/null 2>&1; then
|
||||
echo "{\"text\": \"Not Connected\", \"tooltip\": \"WireGuard is down\", \"alt\": \"disconnected\", \"class\": \"disconnected\"}"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "{\"text\": \"Connected\", \"tooltip\": \"WireGuard connected\", \"alt\": \"connected\", \"class\": \"connected\"}"
|
||||
exit 0
|
||||
Loading…
Add table
Add a link
Reference in a new issue