mirror of
https://github.com/FelixKratz/SketchyBar
synced 2024-11-27 05:40:17 +00:00
143 lines
9.5 KiB
Text
Executable file
143 lines
9.5 KiB
Text
Executable file
# This is a demo config to bring across some of the most important commands more easily.
|
|
# This is meant to be changed and configured, as it is intentionally kept sparse.
|
|
# For a more advanced configuration example see https://github.com/FelixKratz/SketchyBar/discussions/47#discussioncomment-2027233
|
|
|
|
##### Bar Appearance #####
|
|
# Configuring the general appearance of the bar, these are only some of the
|
|
# options available. For all options see:
|
|
# https://felixkratz.github.io/SketchyBar/config/bar
|
|
# If you are looking for other colors, see the color picker:
|
|
# https://felixkratz.github.io/SketchyBar/config/tricks#color-picker
|
|
|
|
sketchybar --bar height=32 \
|
|
blur_radius=50 \
|
|
position=top \
|
|
padding_left=5 \
|
|
padding_right=5 \
|
|
color=0x44000000
|
|
|
|
|
|
##### Changing Defaults #####
|
|
# We now change some default values that are applied to all further items
|
|
# For a full list of all available item properties see:
|
|
# https://felixkratz.github.io/SketchyBar/config/items
|
|
|
|
sketchybar --default updates=when_shown \
|
|
drawing=on \
|
|
icon.font="Hack Nerd Font:Bold:17.0" \
|
|
icon.color=0xffffffff \
|
|
label.font="Hack Nerd Font:Bold:14.0" \
|
|
label.color=0xffffffff \
|
|
label.padding_left=4 \
|
|
label.padding_right=4 \
|
|
icon.padding_left=8 \
|
|
label.padding_right=8
|
|
|
|
##### Adding Mission Control Space Indicators #####
|
|
# Now we add some space components:
|
|
# https://felixkratz.github.io/SketchyBar/config/components#space----associate-mission-control-spaces-with-an-item
|
|
# to indicate active and available mission control spaces
|
|
|
|
sketchybar --add space code left \
|
|
--set code associated_display=1 \
|
|
associated_space=1 \
|
|
icon.font="Hack Nerd Font:Bold:20.0" \
|
|
icon= \
|
|
icon.highlight_color=0xff48aa2a \
|
|
label=code \
|
|
click_script="yabai -m space --focus 1" \
|
|
\
|
|
--add space tex left \
|
|
--set tex associated_display=1 \
|
|
associated_space=2 \
|
|
icon= \
|
|
icon.highlight_color=0xfffab402 \
|
|
label=tex \
|
|
click_script="yabai -m space --focus 2"
|
|
|
|
##### Adding Left Items #####
|
|
# We add some regular items to the left side of the bar
|
|
# only the properties deviating from the current defaults need to be set
|
|
|
|
sketchybar --add item space_separator left \
|
|
--set space_separator icon= \
|
|
associated_space=1 \
|
|
icon.padding_left=15 \
|
|
label.padding_right=15 \
|
|
icon.font="Hack Nerd Font:Bold:15.0" \
|
|
\
|
|
--add item gitNotifications left \
|
|
--set gitNotifications associated_space=1 \
|
|
update_freq=300 \
|
|
icon.font="Hack Nerd Font:Bold:18.0" \
|
|
icon= \
|
|
script="~/.config/sketchybar/plugins/gitNotifications.sh" \
|
|
click_script="open https://github.com/notifications" \
|
|
--subscribe gitNotifications system_woke \
|
|
\
|
|
--add item githubIndicator left \
|
|
--set githubIndicator associated_space=1 \
|
|
update_freq=1000 \
|
|
icon.font="Hack Nerd Font:Bold:18.0" \
|
|
icon= \
|
|
click_script="open https://github.com" \
|
|
script="~/.config/sketchybar/plugins/githubIndicator.sh" \
|
|
--subscribe githubIndicator system_woke \
|
|
\
|
|
--add item topmem left \
|
|
--set topmem associated_space=1 \
|
|
icon.padding_left=10 \
|
|
update_freq=15 \
|
|
script="~/.config/sketchybar/plugins/topmem.sh"
|
|
|
|
##### Adding Right Items #####
|
|
sketchybar --add item clock right \
|
|
--set clock update_freq=10 \
|
|
script="~/.config/sketchybar/plugins/clock.sh" \
|
|
\
|
|
--add item mailIndicator right \
|
|
--set mailIndicator associated_space=1,2,3 \
|
|
update_freq=30 \
|
|
script="~/.config/sketchybar/plugins/mailIndicator.sh" \
|
|
icon.font="Hack Nerd Font:Bold:20.0" \
|
|
icon= \
|
|
click_script="osascript -e 'tell application \"Mail\" to activate'"
|
|
|
|
# Creating a simple CPU Graph
|
|
# https://felixkratz.github.io/SketchyBar/config/components#data-graph----draws-an-arbitrary-graph-into-the-bar
|
|
sketchybar --add graph cpu_user right 200 \
|
|
--set cpu_user graph.color=0xffffffff \
|
|
update_freq=2 \
|
|
width=0 \
|
|
associated_space=1 \
|
|
label.padding_left=0 \
|
|
icon= \
|
|
script="~/.config/sketchybar/plugins/cpu_graph.sh" \
|
|
lazy=on \
|
|
\
|
|
--add graph cpu_sys right 200 \
|
|
--set cpu_sys label.padding_left=0 \
|
|
associated_space=1 \
|
|
icon= \
|
|
graph.color=0xff48aa2a \
|
|
\
|
|
--add item topproc right \
|
|
--set topproc associated_space=1 \
|
|
label.padding_right=10 \
|
|
update_freq=15 \
|
|
script="~/.config/sketchybar/plugins/topproc.sh"
|
|
|
|
##### Adding Center Items #####
|
|
# Adding custom events which can listen on distributed notifications from other running processes:
|
|
# https://felixkratz.github.io/SketchyBar/config/events
|
|
|
|
sketchybar --add event spotify_change "com.spotify.client.PlaybackStateChanged" \
|
|
--add item spotifyIndicator center \
|
|
--set spotifyIndicator script="~/.config/sketchybar/plugins/spotifyIndicator.sh" \
|
|
click_script="osascript -e 'tell application \"Spotify\" to pause'" \
|
|
--subscribe spotifyIndicator spotify_change
|
|
|
|
##### Finalizing Setup #####
|
|
sketchybar --update
|
|
|
|
echo "sketchybar configuration loaded.."
|