Dotfiles V.1.1.5
Updated Neovim Plugins as well as cleaned up aerospace config and sketbar config and added fastfetch config
This commit is contained in:
@@ -1,44 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
export WHITE=0xffeeeeee
|
||||
export WHITE="0xffeeeeee"
|
||||
|
||||
# -- Dracula Scheme --
|
||||
export BAR_COLOR=0xff262626
|
||||
export ITEM_BG_COLOR=0xff4e4e4e
|
||||
export ACCENT_COLOR=0xff8A8FA9
|
||||
|
||||
# -- Gray Scheme --
|
||||
# export BAR_COLOR=0xff101314
|
||||
# export ITEM_BG_COLOR=0xff353c3f
|
||||
# export ACCENT_COLOR=0xffffffff
|
||||
|
||||
# -- Purple Scheme --
|
||||
# export BAR_COLOR=0xff140c42
|
||||
# export ITEM_BG_COLOR=0xff2b1c84
|
||||
# export ACCENT_COLOR=0xffeb46f9
|
||||
|
||||
# -- Red Scheme ---
|
||||
# export BAR_COLOR=0xff23090e
|
||||
# export ITEM_BG_COLOR=0xff591221
|
||||
# export ACCENT_COLOR=0xffff2453
|
||||
|
||||
# -- Blue Scheme ---
|
||||
# export BAR_COLOR=0xff021254
|
||||
# export ITEM_BG_COLOR=0xff093aa8
|
||||
# export ACCENT_COLOR=0xff15bdf9
|
||||
|
||||
# -- Green Scheme --
|
||||
# export BAR_COLOR=0xff003315
|
||||
# export ITEM_BG_COLOR=0xff008c39
|
||||
# export ACCENT_COLOR=0xff1dfca1
|
||||
|
||||
|
||||
# -- Orange Scheme --
|
||||
# export BAR_COLOR=0xff381c02
|
||||
# export ITEM_BG_COLOR=0xff99440a
|
||||
# export ACCENT_COLOR=0xfff97716
|
||||
|
||||
# -- Yellow Scheme --
|
||||
# export BAR_COLOR=0xff2d2b02
|
||||
# export ITEM_BG_COLOR=0xff8e7e0a
|
||||
# export ACCENT_COLOR=0xfff7fc17
|
||||
# -- Catppuccin --
|
||||
export BAR_COLOR="0xff24273a"
|
||||
export ITEM_BG_COLOR="0xff494d64"
|
||||
export RED="0xffed8796"
|
||||
export PEACH="0xfff5a97f"
|
||||
export YELLOW="0xffeed49f"
|
||||
export GREEN="0xffa6da95"
|
||||
export BLUE="0xff8aadf4"
|
||||
export TEXT="0xffcad3f5"
|
||||
export MAUVE="0xffc6a0f6"
|
||||
|
||||
@@ -2,5 +2,12 @@
|
||||
|
||||
sketchybar --add item battery right \
|
||||
--set battery update_freq=120 \
|
||||
script="$PLUGIN_DIR/battery.sh" \
|
||||
script="$PLUGIN_DIR/battery.sh" \
|
||||
click_script="$PLUGIN_DIR/battery_popup.sh" \
|
||||
--subscribe battery system_woke power_source_change
|
||||
|
||||
sketchybar --add item batteryStatus popup.battery
|
||||
|
||||
sketchybar --add item batteryMaintain popup.battery
|
||||
|
||||
sketchybar --add item batteryCharge popup.battery
|
||||
|
||||
10
.config/sketchybar/items/front_app.sh
Executable file
10
.config/sketchybar/items/front_app.sh
Executable file
@@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
sketchybar --add item front_app q \
|
||||
--set front_app background.color=$ITEM_BG_COLOR \
|
||||
icon.color=$BLUE \
|
||||
icon.font="sketchybar-app-font:Regular:16.0" \
|
||||
label.color=$BLUE \
|
||||
script="$PLUGIN_DIR/front_app.sh" \
|
||||
associated_display=1 \
|
||||
--subscribe front_app front_app_switched
|
||||
@@ -1,12 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
sketchybar --add item media e \
|
||||
--set media label.color=$ACCENT_COLOR \
|
||||
label.max_chars=20 \
|
||||
icon.padding_left=0 \
|
||||
scroll_texts=on \
|
||||
icon= \
|
||||
icon.color=$ACCENT_COLOR \
|
||||
background.drawing=off \
|
||||
script="$PLUGIN_DIR/media.sh" \
|
||||
--subscribe media media_change
|
||||
13
.config/sketchybar/items/pomodoro.sh
Executable file
13
.config/sketchybar/items/pomodoro.sh
Executable file
@@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
|
||||
sketchybar --add item pomodoro e \
|
||||
--set pomodoro update_freq=1 \
|
||||
associated_display=1 \
|
||||
script="$PLUGIN_DIR/pomodoro.sh" \
|
||||
click_script="$PLUGIN_DIR/pomodoro_popup.sh"
|
||||
|
||||
sketchybar --add item focus popup.pomodoro
|
||||
|
||||
sketchybar --add item shortBreak popup.pomodoro
|
||||
|
||||
sketchybar --add item longBreak popup.pomodoro
|
||||
@@ -11,7 +11,5 @@ do
|
||||
--set $str icon=$str \
|
||||
associated_display=1 \
|
||||
label.font="sketchybar-app-font:Regular:16.0" \
|
||||
label.padding_right=20 \
|
||||
label.y_offset=-1\
|
||||
script="$PLUGIN_DIR/space.sh $str"
|
||||
done
|
||||
|
||||
5
.config/sketchybar/items/wifi.sh
Executable file
5
.config/sketchybar/items/wifi.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
sketchybar --add item wifi right \
|
||||
--set wifi update_freq=10 \
|
||||
script="$PLUGIN_DIR/wifi.sh"
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
PERCENTAGE="$(pmset -g batt | grep -Eo "\d+%" | cut -d% -f1)"
|
||||
CHARGING="$(pmset -g batt | grep 'AC Power')"
|
||||
@@ -8,21 +8,32 @@ if [ "$PERCENTAGE" = "" ]; then
|
||||
fi
|
||||
|
||||
case "${PERCENTAGE}" in
|
||||
9[0-9]|100) ICON=""
|
||||
9[0-9]|100)
|
||||
ICON=""
|
||||
COLOR="0xFFA6DA95"
|
||||
;;
|
||||
[6-8][0-9]) ICON=""
|
||||
[6-8][0-9])
|
||||
ICON=""
|
||||
COLOR="0xFFEED49F"
|
||||
;;
|
||||
[3-5][0-9]) ICON=""
|
||||
[3-5][0-9])
|
||||
ICON=""
|
||||
COLOR="0xFFF5A97F"
|
||||
;;
|
||||
[1-2][0-9]) ICON=""
|
||||
[1-2][0-9])
|
||||
ICON=""
|
||||
COLOR="0xFFED8796"
|
||||
;;
|
||||
*) ICON=""
|
||||
*)
|
||||
ICON=""
|
||||
COLOR="0xFFED8796"
|
||||
esac
|
||||
|
||||
if [[ "$CHARGING" != "" ]]; then
|
||||
ICON=""
|
||||
COLOR="0xFFA6DA95"
|
||||
fi
|
||||
|
||||
# The item invoking this script (name $NAME) will get its icon and label
|
||||
# updated with the current battery status
|
||||
sketchybar --set "$NAME" icon="$ICON" label="${PERCENTAGE}%"
|
||||
sketchybar --set "$NAME" icon.color="$COLOR" icon="$ICON" label.color="$COLOR" label="${PERCENTAGE}%"
|
||||
|
||||
31
.config/sketchybar/plugins/battery_popup.sh
Executable file
31
.config/sketchybar/plugins/battery_popup.sh
Executable file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
|
||||
sketchybar --set battery popup.drawing=toggle \
|
||||
popup.background.drawing=on \
|
||||
popup.background.color="0xff363a4f" \
|
||||
popup.background.corner_radius=3
|
||||
|
||||
|
||||
if /usr/local/bin/battery status | grep -q 'Your battery'; then
|
||||
sketchybar --set batteryStatus label="Maintaining" \
|
||||
label.color="0xffa6da95"
|
||||
sketchybar --set batteryMaintain label="Stop Maintaining" \
|
||||
label.color="0xffed8796" \
|
||||
click_script="/usr/local/bin/battery maintain stop && sketchybar --set battery popup.drawing=toggle"
|
||||
else
|
||||
sketchybar --set batteryStatus label="Not Maintaining" \
|
||||
label.color="0xffed8796"
|
||||
sketchybar --set batteryMaintain label="Maintain" \
|
||||
label.color="0xffa6da95" \
|
||||
click_script="/usr/local/bin/battery maintain 80 && sketchybar --set battery popup.drawing=toggle"
|
||||
fi
|
||||
|
||||
if [[ "$CHARGING" != "" ]]; then
|
||||
sketchybar --set batteryCharge label="Stop Charging" \
|
||||
label.color="0xffed8796"\
|
||||
click_script="/usr/local/bin/battery charging off && sketchybar --set battery popup.drawing=toggle"
|
||||
else
|
||||
sketchybar --set batteryCharge label="Start Charging" \
|
||||
label.color="0xffa6da95"\
|
||||
click_script="/usr/local/bin/battery charging on && sketchybar --set battery popup.drawing=toggle"
|
||||
fi
|
||||
5
.config/sketchybar/plugins/front_app.sh
Executable file
5
.config/sketchybar/plugins/front_app.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ "$SENDER" = "front_app_switched" ]; then
|
||||
sketchybar --set $NAME label="$INFO" icon="$($CONFIG_DIR/plugins/icon_map_fn.sh "$INFO")"
|
||||
fi
|
||||
@@ -1,4 +1,3 @@
|
||||
#!/bin/bash
|
||||
|
||||
function icon_map() {
|
||||
case "$1" in
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
STATE="$(echo "$INFO" | jq -r '.state')"
|
||||
if [ "$STATE" = "playing" ]; then
|
||||
MEDIA="$(echo "$INFO" | jq -r '.title + " - " + .artist')"
|
||||
sketchybar --set $NAME label="$MEDIA" drawing=on
|
||||
else
|
||||
sketchybar --set $NAME drawing=off
|
||||
fi
|
||||
20
.config/sketchybar/plugins/pomodoro.sh
Executable file
20
.config/sketchybar/plugins/pomodoro.sh
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/bin/bash
|
||||
|
||||
STATUS=$(/usr/local/bin/pomodoro status)
|
||||
|
||||
if [ -z "$STATUS" ]; then
|
||||
sketchybar --set pomodoro icon="" \
|
||||
label="Start a Session!" \
|
||||
icon.color="0xffed8796" \
|
||||
label.color="0xffed8796"
|
||||
elif /usr/local/bin/pomodoro status | grep -q "❗"; then
|
||||
sketchybar --set pomodoro icon="" \
|
||||
label="Good Job!" \
|
||||
icon.color="0xffed8796" \
|
||||
label.color="0xffed8796"
|
||||
elif /usr/local/bin/pomodoro status | grep -q "🍅"; then
|
||||
sketchybar --set pomodoro icon="" \
|
||||
label="$(/usr/local/bin/pomodoro status -f "%r")" \
|
||||
icon.color="0xfff5bde6" \
|
||||
label.color="0xfff5bde6"
|
||||
fi
|
||||
40
.config/sketchybar/plugins/pomodoro_popup.sh
Executable file
40
.config/sketchybar/plugins/pomodoro_popup.sh
Executable file
@@ -0,0 +1,40 @@
|
||||
#!/bin/sh
|
||||
|
||||
sketchybar --set pomodoro popup.drawing=toggle \
|
||||
popup.background.drawing=on \
|
||||
popup.background.color="0xff363a4f" \
|
||||
popup.background.corner_radius=3
|
||||
|
||||
STATUS=$(/usr/local/bin/pomodoro status)
|
||||
|
||||
if [ "$STATUS" = "" ]; then
|
||||
sketchybar --set focus icon="" \
|
||||
label="Focus 50:00" \
|
||||
icon.color="0xfff5bde6" \
|
||||
label.color="0xfff5bde6" \
|
||||
click_script="/usr/local/bin/pomodoro start --duration 50 && sketchybar --set pomodoro popup.drawing=toggle"
|
||||
sketchybar --set shortBreak icon="" \
|
||||
label="Short Break 5:00" \
|
||||
icon.color="0xffcad3f5" \
|
||||
label.color="0xffcad3f5"
|
||||
sketchybar --set longBreak icon="" \
|
||||
label="Long Break 15:00" \
|
||||
icon.color="0xffcad3f5" \
|
||||
label.color="0xffcad3f5"
|
||||
else
|
||||
sketchybar --set focus icon="" \
|
||||
label="Focus 50:00" \
|
||||
icon.color="0xfff5bde6" \
|
||||
label.color="0xfff5bde6" \
|
||||
click_script="/usr/local/bin/pomodoro start --duration 50 && sketchybar --set pomodoro popup.drawing=toggle"
|
||||
sketchybar --set shortBreak icon="" \
|
||||
label="Short Break 5:00" \
|
||||
icon.color="0xff91d7e3" \
|
||||
label.color="0xff91d7e3" \
|
||||
click_script="sketchybar --set pomodoro update_freq=0 icon='' label='Break Time!' icon.color='0xff91d7e3' label.color='0xff91d7e3' popup.drawing=toggle && /usr/local/bin/pomodoro break && sketchybar --set pomodoro update_freq=1"
|
||||
sketchybar --set longBreak icon="" \
|
||||
label="Long Break 15:00" \
|
||||
icon.color="0xff91d7e3" \
|
||||
label.color="0xff91d7e3" \
|
||||
click_script="sketchybar --set pomodoro update_freq=0 icon='' label='Break Time!' icon.color='0xff91d7e3' label.color='0xff91d7e3' popup.drawing=toggle && /usr/local/bin/pomodoro break 15 && sketchybar --set pomodoro update_freq=1"
|
||||
fi
|
||||
@@ -4,29 +4,11 @@ source "$CONFIG_DIR/colors.sh"
|
||||
|
||||
if [ "$1" = "$FOCUSED_WORKSPACE" ]; then
|
||||
sketchybar --set $NAME background.drawing=on \
|
||||
background.color=$ACCENT_COLOR \
|
||||
background.color=$BLUE \
|
||||
label.color=$BAR_COLOR \
|
||||
icon.color=$BAR_COLOR
|
||||
else
|
||||
sketchybar --set $NAME background.drawing=off \
|
||||
label.color=$ACCENT_COLOR \
|
||||
icon.color=$ACCENT_COLOR
|
||||
fi
|
||||
|
||||
if [ "$SENDER" = "aerospace_workspace_change" ]; then
|
||||
|
||||
apps=$(aerospace list-windows --workspace $1 | awk -F'|' '{gsub(/^ *| *$/, "", $2); print $2}')
|
||||
|
||||
icon_strip=" "
|
||||
if [ "${apps}" != "" ]; then
|
||||
while read -r app
|
||||
do
|
||||
icon_strip+=" $($CONFIG_DIR/plugins/icon_map_fn.sh "$app")"
|
||||
done <<< "${apps}"
|
||||
else
|
||||
icon_strip=" —"
|
||||
fi
|
||||
|
||||
sketchybar --set $1 label="$icon_strip"
|
||||
|
||||
label.color=$BLUE \
|
||||
icon.color=$BLUE
|
||||
fi
|
||||
|
||||
@@ -7,14 +7,20 @@ if [ "$SENDER" = "volume_change" ]; then
|
||||
VOLUME="$INFO"
|
||||
|
||||
case "$VOLUME" in
|
||||
[6-9][0-9]|100) ICON=""
|
||||
[6-9][0-9]|100)
|
||||
ICON=""
|
||||
COLOR="0xff8aadf4"
|
||||
;;
|
||||
[3-5][0-9]) ICON=""
|
||||
[3-5][0-9])
|
||||
ICON=""
|
||||
COLOR="0xff8aadf4"
|
||||
;;
|
||||
[1-9]|[1-2][0-9]) ICON=""
|
||||
;;
|
||||
*) ICON=""
|
||||
*)
|
||||
ICON=""
|
||||
COLOR="0xffed8796"
|
||||
esac
|
||||
|
||||
sketchybar --set "$NAME" icon="$ICON" label="$VOLUME%"
|
||||
sketchybar --set "$NAME" icon.color="$COLOR" icon="$ICON" label.color="$COLOR" label="$VOLUME%"
|
||||
fi
|
||||
|
||||
21
.config/sketchybar/plugins/wifi.sh
Executable file
21
.config/sketchybar/plugins/wifi.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/sh
|
||||
|
||||
if networksetup -getairportpower en0 | grep -q "On"; then
|
||||
SSID=$(ipconfig getsummary en0 | awk -F ' SSID : ' '/ SSID : / {print $2}')
|
||||
if [ -z "$SSID" ]; then
|
||||
sketchybar --set wifi icon="" \
|
||||
label="Disconnected" \
|
||||
label.color="0xffed8796" \
|
||||
icon.color="0xffed8796"
|
||||
else
|
||||
sketchybar --set wifi icon="" \
|
||||
label="$SSID" \
|
||||
label.color="0xffc6a0f6" \
|
||||
icon.color="0xffc6a0f6"
|
||||
fi
|
||||
else
|
||||
sketchybar --set wifi icon="" \
|
||||
label="Off" \
|
||||
label.color="0xffed8796" \
|
||||
icon.color="0xffed8796"
|
||||
fi
|
||||
@@ -9,6 +9,7 @@ source "$CONFIG_DIR/colors.sh"
|
||||
|
||||
PLUGIN_DIR="$CONFIG_DIR/plugins"
|
||||
ITEM_DIR="$CONFIG_DIR/items"
|
||||
HELPER_DIR="$CONFIG_DIR/helper"
|
||||
|
||||
##### Bar Appearance #####
|
||||
# Configuring the general appearance of the bar.
|
||||
@@ -17,7 +18,7 @@ ITEM_DIR="$CONFIG_DIR/items"
|
||||
# If you are looking for other colors, see the color picker:
|
||||
# https://felixkratz.github.io/SketchyBar/config/tricks#color-picker
|
||||
|
||||
sketchybar --bar position=top height=30 blur_radius=30 color=$BAR_COLOR
|
||||
sketchybar --bar position=top height=40 blur_radius=30 color=$BAR_COLOR notch_width=220
|
||||
|
||||
##### Changing Defaults #####
|
||||
# We now change some default values, which are applied to all further items.
|
||||
@@ -27,10 +28,8 @@ sketchybar --bar position=top height=30 blur_radius=30 color=$BAR_COLOR
|
||||
default=(
|
||||
padding_left=5
|
||||
padding_right=5
|
||||
icon.font="MesloLGS Nerd Font:Bold:17.0"
|
||||
label.font="MesloLGS Nerd Font:Bold:14.0"
|
||||
icon.color=$WHITE
|
||||
label.color=$WHITE
|
||||
icon.font="JetBrainsMono Nerd Font:Bold:17.0"
|
||||
label.font="JetBrainsMono Nerd Font:Bold:14.0"
|
||||
background.color=$ITEM_BG_COLOR
|
||||
background.corner_radius=5
|
||||
background.height=24
|
||||
@@ -47,13 +46,15 @@ source $ITEM_DIR/spaces.sh
|
||||
|
||||
# --Middle Items --
|
||||
|
||||
source $ITEM_DIR/media.sh
|
||||
source $ITEM_DIR/front_app.sh
|
||||
source $ITEM_DIR/pomodoro.sh
|
||||
|
||||
# --Right Side Items --
|
||||
|
||||
source $ITEM_DIR/calendar.sh
|
||||
source $ITEM_DIR/volume.sh
|
||||
source $ITEM_DIR/battery.sh
|
||||
source $ITEM_DIR/wifi.sh
|
||||
|
||||
##### Force all scripts to run the first time (never do this in a script) #####
|
||||
sketchybar --update
|
||||
|
||||
Reference in New Issue
Block a user