diff --git a/dotfiles/fish/.config/fish/functions/now.fish b/dotfiles/fish/.config/fish/functions/now.fish new file mode 100644 index 0000000..56f9503 --- /dev/null +++ b/dotfiles/fish/.config/fish/functions/now.fish @@ -0,0 +1,3 @@ +function now --wraps='date +%a%l:%M%p' --description 'alias now date +%a%l:%M%p' + date +%a%l:%M%p $argv; +end diff --git a/dotfiles/lemonbar/.config/lemonbar/lemonbar.fish b/dotfiles/lemonbar/.config/lemonbar/lemonbar.fish new file mode 100755 index 0000000..8d58091 --- /dev/null +++ b/dotfiles/lemonbar/.config/lemonbar/lemonbar.fish @@ -0,0 +1,25 @@ +#!/usr/bin/fish + + +while true + set batt_str (battery) + set batt_emoji = "" + + switch $batt_str + case "Full*" + set batt_emoji "✔️" + set batt (battery | cut -d ' ' -f2)% + case 'Discharging*' + set batt_emoji "🔋" + set batt (battery | cut -d ' ' -f2)% + case 'Not*' + set batt_emoji "X" + set batt (battery | cut -d ' ' -f3)% + case 'Charging*' + set batt_emoji "⚡" + set batt (battery | cut -d ' ' -f2)% + end + + echo -e "%{c}$(now) %{r}$(sugar --lb) $batt_emoji $batt " + sleep 1 +end