dotfiles

regexghost dotfiles and scripts
git clone https://git.regexghost.com/dotfiles.git
Log | Files | Refs | README

commit 0e539292a4fa0f9b8640ad657d91a3067c623b3e
parent 1a3cfb29fc623f95586368bac4f10529b79692c3
Author: regexghost <regexghost@protonmail.com>
Date:   Sun, 10 May 2026 12:36:24 +0100

started adding colour-logic, and split metoffice.sh into 2 scripts

Diffstat:
Mdotfiles/.config/gtk2rc | 8++------
Ajwm/.config/jwm/Colorscheme-Substitution-Srcery-jwmrc | 58++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Mjwm/.config/jwm/jwmrc | 88+++++++++++++++++++++++++------------------------------------------------------
Mlists/dotfiles | 1+
Mpanel-scripts/Makefile | 1+
Mpanel-scripts/lemonbar-bar.sh | 46++++++++++++++++++++++++++--------------------
Mpanel-scripts/metoffice.sh | 129++-----------------------------------------------------------------------------
Apanel-scripts/weather-formatter.sh | 110+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Msetup.sh | 6+++---
9 files changed, 232 insertions(+), 215 deletions(-)

diff --git a/dotfiles/.config/gtk2rc b/dotfiles/.config/gtk2rc @@ -1,10 +1,6 @@ -# DO NOT EDIT! This file will be overwritten by LXAppearance. -# Any customization should be done in ~/.gtkrc-2.0.mine instead. - -include "/home/USER_USERNAME/.gtkrc-2.0.mine" -gtk-theme-name="Greybird-dark" +gtk-theme-name="Industrial" gtk-icon-theme-name="Papirus-Dark" -gtk-font-name="Roboto 12" +gtk-font-name="Fira Code 10" gtk-cursor-theme-name="Adwaita" gtk-cursor-theme-size=0 gtk-toolbar-style=GTK_TOOLBAR_BOTH diff --git a/jwm/.config/jwm/Colorscheme-Substitution-Srcery-jwmrc b/jwm/.config/jwm/Colorscheme-Substitution-Srcery-jwmrc @@ -0,0 +1,58 @@ + <!-- Start Substitute - Colorscheme --> + <WindowStyle decorations="motif"> + <Font>Fira Code:bold</Font> + <Width>4</Width> + <Corner>0</Corner> + <Foreground>#FCE8C3</Foreground> + <Background>#1C1B19</Background> + <Opacity>1.0</Opacity> + <Active> + <Foreground>#FCE8C3</Foreground> + <Background>#519F50</Background> + <Opacity>1.0</Opacity> + </Active> + </WindowStyle> + <TrayStyle decorations="motif"> + <Font>Fire Code-11</Font> + <Background>#1C1B19</Background> + <Foreground>#FCE8C3</Foreground> + <Opacity>0.75</Opacity> + </TrayStyle> + <TaskListStyle list="desktop" group="false"> + <Font>Fira Code-11</Font> + <Active> + <Foreground>#FCE8C3</Foreground> + <Background>#519F50</Background> + </Active> + <Minimized> + <Foreground>#FCE8C3</Foreground> + <Background>#111111</Background> + </Minimized> + <Foreground>#FCE8C3</Foreground> + <Background>#333333</Background> + </TaskListStyle> + <PagerStyle> + <Foreground>#1C1B19</Foreground> + <Background>#333333</Background> + <Text>#FCE8C3</Text> + <Active> + <Foreground>#2C78BF</Foreground> + <Background>#004488</Background> + </Active> + </PagerStyle> + <MenuStyle decorations="motif"> + <Font>Fira Code-11</Font> + <Foreground>#FCE8C3</Foreground> + <Background>#333333</Background> + <Active> + <Foreground>#FCE8C3</Foreground> + <Background>#2C78BF</Background> + </Active> + <Opacity>0.85</Opacity> + </MenuStyle> + <PopupStyle> + <Font>Fira Code-11</Font> + <Foreground>#000000</Foreground> + <Background>#999999</Background> + </PopupStyle> + <!-- End Substitute --> diff --git a/jwm/.config/jwm/jwmrc b/jwm/.config/jwm/jwmrc @@ -43,9 +43,14 @@ <Option>drag</Option> <Option>notitle</Option> </Group> + <Group> + <Name>lemonbar</Name> + <Option>nopager</Option> + <Option>nolist</Option> + </Group> <!-- Tray at the bottom. --> - <Tray x="0" y="0" autohide="off" delay="1000"> + <Tray x="0" y="0" autohide="off" delay="1000" height="26" width="960"> <TrayButton label="JWM">root:1</TrayButton> <Spacer width="2"/> @@ -54,7 +59,7 @@ <Pager labeled="true"/> - <TaskList maxwidth="256"/> + <TaskList maxwidth="80"/> <Swallow width="32" height="32" name="xclock">xclock</Swallow> @@ -64,62 +69,7 @@ </Tray> <!-- Visual Styles --> - <WindowStyle decorations="motif"> - <Font>Sans-12:bold</Font> - <Width>4</Width> - <Corner>0</Corner> - <Foreground>#FCE8C3</Foreground> - <Background>#1C1B19</Background> - <Opacity>1.0</Opacity> - <Active> - <Foreground>#FCE8C3</Foreground> - <Background>#519F50</Background> - <Opacity>1.0</Opacity> - </Active> - </WindowStyle> - <TrayStyle decorations="motif"> - <Font>Sans-12</Font> - <Background>#1C1B19</Background> - <Foreground>#FCE8C3</Foreground> - <Opacity>0.75</Opacity> - </TrayStyle> - <TaskListStyle list="desktop" group="true"> - <Font>Sans-12</Font> - <Active> - <Foreground>#FCE8C3</Foreground> - <Background>#519F50</Background> - </Active> - <Minimized> - <Foreground>#FCE8C3</Foreground> - <Background>#111111</Background> - </Minimized> - <Foreground>#FCE8C3</Foreground> - <Background>#333333</Background> - </TaskListStyle> - <PagerStyle> - <Foreground>#1C1B19</Foreground> - <Background>#333333</Background> - <Text>#FCE8C3</Text> - <Active> - <Foreground>#2C78BF</Foreground> - <Background>#004488</Background> - </Active> - </PagerStyle> - <MenuStyle decorations="motif"> - <Font>Sans-12</Font> - <Foreground>#FCE8C3</Foreground> - <Background>#333333</Background> - <Active> - <Foreground>#FCE8C3</Foreground> - <Background>#2C78BF</Background> - </Active> - <Opacity>0.85</Opacity> - </MenuStyle> - <PopupStyle> - <Font>Sans-12</Font> - <Foreground>#000000</Foreground> - <Background>#999999</Background> - </PopupStyle> + <!-- Start Substitute - Colorscheme --> <!-- Path where icons can be found. IconPath can be listed multiple times to allow searching @@ -211,10 +161,28 @@ <Key mask="4" key="apostrophe">maximize</Key> <Key mask="4" key="slash">minimize</Key> - + <Key mask="4S" key="r">resize</Key> + + <Key mask="4" key="m">exec:~/.local/share/regexghost/panel/music.sh</Key> + <Key mask="4S" key="m">exec:~/.local/share/regexghost/panel/music.sh --choice</Key> + <Key mask="4" key="equal">exec:~/.local/share/regexghost/panel/music.sh --next</Key> + <Key mask="4" key="minus">exec:~/.local/share/regexghost/panel/music.sh --previous</Key> + <Key mask="4S" key="minus">exec:~/.local/share/regexghost/panel/music.sh --quit</Key> + <Key mask="4S" key="equal">exec:~/.local/share/regexghost/panel/music.sh --favourite</Key> + <Key mask="4S" key="bracketleft">exec:~/.local/share/regexghost/panel/music.sh --toggle-pause</Key> + <Key mask="4" key="bracketleft">exec:~/.local/share/regexghost/wm-scripts/volume.sh --down</Key> + <Key mask="4" key="bracketright">exec:~/.local/share/regexghost/wm-scripts/volume.sh --up</Key> + <Key mask="4S" key="slash">exec:~/.local/share/regexghost/wm-scripts/volume.sh --toggle-mute</Key> <Key mask="4" key="Return">exec:st</Key> + <Key mask="4S" key="Return">exec:xterm</Key> <Key mask="4" key="b">exec:st -t btop -e btop</Key> - + <Key mask="4" key="w">exec:netsurf-gtk</Key> + <Key mask="4" key="n">exec:st -t nethogs -e nethogs</Key> + <Key mask="4" key="u">exec:st -t cava -e cava</Key> + <Key mask="4" key="c">exec:st -t qalc -e qalc</Key> + <Key mask="4" key="e">exec:st -t ranger -e ranger</Key> + <Key mask="4S" key="e">exec:xfiles</Key> + <Key mask="4" key="q">exec:~/.local/share/regexghostw/</Key> <!-- Mouse bindings --> <!-- <Mouse context="root" button="4">ldesktop</Mouse> --> diff --git a/lists/dotfiles b/lists/dotfiles @@ -25,3 +25,4 @@ ~/.bashrc ~/.xinitrc ~/.vimrc +~/.config/dunst/dunstrc diff --git a/panel-scripts/Makefile b/panel-scripts/Makefile @@ -7,6 +7,7 @@ normal: gcc -o network_down network.c cp sunrise.sh ${PREFIX}/sunrise.sh cp metoffice.sh ${PREFIX}/metoffice.sh + cp weather-formatter.sh ${PREFIX}/weather-formatter.sh cp music.sh ${PREFIX}/music.sh cp lemonbar-bar.sh ${PREFIX}/lemonbar-bar.sh cp lemonbar-runner.sh ${PREFIX}/lemonbar-runner.sh diff --git a/panel-scripts/lemonbar-bar.sh b/panel-scripts/lemonbar-bar.sh @@ -2,59 +2,65 @@ echo "$$" > ~/.cache/bar_pid +. "$XDG_CONFIG_HOME/regexghost/current-theme.sh" + COLOUR_RESET="%{F-}" -sunset_colour="%{F#EF2F27}" -sunrise_colour="%{F#FBB829}" -network_down_colour="%{F#E02C6D}" -cpu_colour="%{F#2C78BF}" -cpu_temp_colour="%{F#EF2F27}" -memory_colour="%{F#FBB829}" -uptime_colour="%{F#519F50}" -muted_colour="%{F#EF2F27}" -volume_colour="%{F#519F50}" +sunset_colour="%{F#${RED}}" +sunrise_colour="%{F#${YELLOW}}" +network_down_colour="%{F#${MAGENTA}}" +cpu_colour="%{F#${BLUE}}" +cpu_temp_colour="%{F#${RED}}" +memory_colour="%{F#${YELLOW}}" +uptime_colour="%{F#${GREEN}}" +muted_colour="%{F#${RED}}" +volume_colour="%{F#${GREEN}}" update_time () { current_time="$(date +"%b, %a %d - %H:%M")" } update_cpu () { - cpu="$(~/.local/share/regexghost/panel/cpu)%" + cpu="${cpu_colour} $(~/.local/share/regexghost/panel/cpu)%${COLOUR_RESET}" } update_network_down () { - network_down=$(~/.local/share/regexghost/panel/network_down) + network_down="${network_down_colour} "$(~/.local/share/regexghost/panel/network_down)"${COLOUR_RESET}" } update_vol () { if [ $(cat ~/.cache/muted) = "yes" ]; then - vol="${muted_colour} : Muted${COLOUR_RESET}" + vol="${muted_colour} Muted${COLOUR_RESET}" else - vol="${volume_colour} : $(cat ~/.cache/volume)%%${COLOUR_RESET}" + vol="${volume_colour} $(cat ~/.cache/volume)%%${COLOUR_RESET}" fi } update_mem () { - memory=$(free -m | awk '/Mem:/ {print $3}')MiB + memory="${memory_colour} "$(free -m | awk '/Mem:/ {print $3}')MiB"${COLOUR_RESET}" } update_cpu_temp () { - cpu_temp=$(vcgencmd measure_temp | cut -d "=" -f 2) + cpu_temp="${cpu_temp_colour} "$(vcgencmd measure_temp | cut -d "=" -f 2)"${COLOUR_RESET}" } update_uptime () { - uptime=$(~/.local/share/regexghost/panel/uptime) + uptime="${uptime_colour} "$(~/.local/share/regexghost/panel/uptime)"${COLOUR_RESET}" } update_sunrise () { - sunrise=$(~/.local/share/regexghost/panel/sunrise.sh --sunrise --blank) + sunrise="${sunrise_colour} "$(~/.local/share/regexghost/panel/sunrise.sh --sunrise --blank)"${COLOUR_RESET}" } update_sunset () { - sunset=$(~/.local/share/regexghost/panel/sunrise.sh --sunset --blank) + sunset="${sunset_colour} "$(~/.local/share/regexghost/panel/sunrise.sh --sunset --blank)"${COLOUR_RESET}" } update_weather () { - weather="$(~/.local/share/regexghost/panel/metoffice.sh --lemonbar)" + weather_days="$(~/.local/share/regexghost/panel/metoffice.sh)" + weather_today="$(~/.local/share/regexghost/panel/weather-formatter.sh --lemonbar "$(echo "$weather_days" | sed '1q;d')")" + weather_tomorrow="$(~/.local/share/regexghost/panel/weather-formatter.sh --lemonbar "$(echo "$weather_days" | sed '2q;d')")" + weather_2_days="$(~/.local/share/regexghost/panel/weather-formatter.sh --lemonbar "$(echo "$weather_days" | sed '3q;d')")" + weather="0 ${weather_today} 1 ${weather_tomorrow} 2 ${weather_2_days}" } # @@ -79,7 +85,7 @@ update_weather () { # display () { - echo "%{r} ${sunset_colour}: ${sunset}${COLOUR_RESET} | ${sunrise_colour} : ${sunrise}${COLOUR_RESET} | ${weather} | ${vol} | ${network_down_colour} ${network_down}${COLOUR_RESET} | ${cpu_colour} : ${cpu}${COLOUR_RESET} | ${uptime_colour} : ${uptime}${COLOUR_RESET} | ${cpu_temp_colour}: ${cpu_temp}${COLOUR_RESET} | ${memory_colour} : ${memory}${COLOUR_RESET} | ${current_time} " + echo "%{r} ${sunset} | ${sunrise} | ${weather} | ${vol} | ${network_down} | ${cpu} | ${uptime} | ${cpu_temp} | ${memory} | ${current_time} " } update_vol diff --git a/panel-scripts/metoffice.sh b/panel-scripts/metoffice.sh @@ -2,30 +2,8 @@ # This script is quite ugly and needs re-writing, but it works for now -theme=$(cat "$XDG_CONFIG_HOME/regexghost/current_theme.txt") - [ -d "/tmp/panel_i3_data" ] || mkdir "/tmp/panel_i3_data" -if [[ "$theme" == "dracula" ]]; then - whiteColour="f8f8f1" - greyColour="a1a3ac" - redColour="e64747" - yellowColour="ffff80" - blueColour="8be9fd" -elif [[ "$theme" == "christmas" ]]; then - whiteColour="F8F8F0" - greyColour="a1a3ac" - redColour="DD4D44" - yellowColour="F1C769" - blueColour="8be9fd" -elif [[ "$theme" == "tube" ]]; then - whiteColour="ffffff" - greyColour="737171" - redColour="ee2e24" - yellowColour="ffd204" - blueColour="009ddc" -fi - curLocationFile="$XDG_CONFIG_HOME/regexghost/current_location.csv" lat=$(cat "$curLocationFile" | cut -d "|" -f 1) @@ -40,107 +18,6 @@ icon_name_today=$(cat "/tmp/panel_i3_data/metoffice.html" | grep -A 5 -B 5 -i "d icon_name_tomorrow=$(cat "/tmp/panel_i3_data/metoffice.html" | grep -A 5 -B 5 -i "datetime=\"$tomorrow_string\"" | grep "class=\"tab-icon\"" | sed 's/;" class.*//g' | sed 's/.*alt="//g') icon_name_second_day=$(cat "/tmp/panel_i3_data/metoffice.html" | grep -A 5 -B 5 -i "datetime=\"$second_day_string\"" | grep "class=\"tab-icon\"" | sed 's/;" class.*//g' | sed 's/.*alt="//g') -function format() { - icon_name="$1" - if [[ "$2" == "conky" ]]; then - if [[ "$icon_name" == "Sunny day" ]]; then - echo "\${color #$yellowColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Light shower day" ]]; then - echo "\${color #$whiteColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Sunny intervals" ]]; then - echo "\${color #$yellowColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Light rain" ]]; then - echo "\${color #$greyColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Heavy rain" ]]; then - echo "\${color #$blueColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Cloudy" ]]; then - echo "\${color #$whiteColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Overcast" ]]; then - echo "\${color #$greyColour}\${font4}  \${font}\${color}" - elif [[ "$icon_name" == "Light snow shower day" ]]; then - echo "\${color #$whiteColour}\${font4}  \${font}\${color}" - else - echo "\${color #$redColour}\${font4}  \${font}\${color}" - fi - elif [[ "$2" == "lemonbar" ]]; then - if [[ "$icon_name" == "Sunny day" ]]; then - echo "%{F#$yellowColour}  %{F-}" - elif [[ "$icon_name" == "Light shower day" ]]; then - echo "%{F#$whiteColour}  %{F-}" - elif [[ "$icon_name" == "Sunny intervals" ]]; then - echo "%{F#$yellowColour}  %{F-}" - elif [[ "$icon_name" == "Light rain" ]]; then - echo "%{F#$greyColour}  %{F-}" - elif [[ "$icon_name" == "Heavy rain" ]]; then - echo "%{F#$blueColour}  %{F-}" - elif [[ "$icon_name" == "Cloudy" ]]; then - echo "%{F#$whiteColour}  %{F-}" - elif [[ "$icon_name" == "Overcast" ]]; then - echo "%{F#$greyColour}  %{F-}" - elif [[ "$icon_name" == "Light snow shower day" ]]; then - echo "%{F#$whiteColour}  %{F-}" - else - echo "%{F#$redColour}  %{F-}" - fi - else - if [[ "$icon_name" == "Sunny day" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$yellowColour'>  </span>" - elif [[ "$icon_name" == "Light shower day" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$whiteColour'>  </span>" - elif [[ "$icon_name" == "Sunny intervals" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$yellowColour'>  </span>" - elif [[ "$icon_name" == "Light rain" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$greyColour'>  </span>" - elif [[ "$icon_name" == "Heavy rain" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$blueColour'>  </span>" - elif [[ "$icon_name" == "Cloudy" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$whiteColour'>  </span>" - elif [[ "$icon_name" == "Overcast" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$greyColour'>  </span>" - elif [[ "$icon_name" == "Light snow shower day" ]]; then - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$whiteColour'>  </span>" - else - echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$redColour'>  </span>" - fi - fi -} - -if [[ "$1" == "--conky" ]]; then - echo "0:$(format "$icon_name_today" conky) 1:$(format "$icon_name_tomorrow" conky) 2:$(format "$icon_name_second_day" conky)" -elif [[ "$1" == "--lemonbar" ]]; then - echo "0:$(format "$icon_name_today" lemonbar) 1:$(format "$icon_name_tomorrow" lemonbar) 2:$(format "$icon_name_second_day" lemonbar)" - -else - echo "0:$(format "$icon_name_today") 1:$(format "$icon_name_tomorrow") 2:$(format "$icon_name_second_day")" -fi - -# moon rain  -# heavy showers -# snow  -# lightning  -# bolt  -# sun  -# moon  -# smog  -# tornado  -# cloud showers water  -# cloud moon  -# hurricane  -# water  -# wind  -# bolt lightning  -# umbrella  -# volcano  -# temperature half  -# temperature three quarters  -# temperature quarter  -# temperature low  -# temperature high  -# temperature full  -# temperature empty  -# temperature arrow up  -# temperature arrow down  -# sun plant wilt  -# rainbow  -# icicles  -# house tsunami  +echo "$icon_name_today" +echo "$icon_name_tomorrow" +echo "$icon_name_second_day" diff --git a/panel-scripts/weather-formatter.sh b/panel-scripts/weather-formatter.sh @@ -0,0 +1,110 @@ +#!/usr/bin/env bash + +# Formatter for weather conditions +# Takes string (e.g. "Overcast Sunny") and outputs icon with colour formatting + +source "$XDG_CONFIG_HOME/regexghost/current-theme.sh" + +function format() { + icon_name="$1" + if [[ "$2" == "conky" ]]; then + if [[ "$icon_name" == "Sunny day" ]]; then + echo "\${color #$YELLOW}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Light shower day" ]]; then + echo "\${color #$WHITE}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Sunny intervals" ]]; then + echo "\${color #$YELLOW}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Light rain" ]]; then + echo "\${color #$BRIGHT_BLACK}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Heavy rain" ]]; then + echo "\${color #$BLUE}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Cloudy" ]]; then + echo "\${color #$WHITE}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Overcast" ]]; then + echo "\${color #$BRIGHT_BLACK}\${font4}  \${font}\${color}" + elif [[ "$icon_name" == "Light snow shower day" ]]; then + echo "\${color #$WHITE}\${font4}  \${font}\${color}" + else + echo "\${color #$RED}\${font4}  \${font}\${color}" + fi + elif [[ "$2" == "lemonbar" ]]; then + if [[ "$icon_name" == "Sunny day" ]]; then + echo "%{F#$YELLOW}  %{F-}" + elif [[ "$icon_name" == "Light shower day" ]]; then + echo "%{F#$WHITE}  %{F-}" + elif [[ "$icon_name" == "Sunny intervals" ]]; then + echo "%{F#$YELLOW}  %{F-}" + elif [[ "$icon_name" == "Light rain" ]]; then + echo "%{F#$BRIGHT_BLACK}  %{F-}" + elif [[ "$icon_name" == "Heavy rain" ]]; then + echo "%{F#$BLUE}  %{F-}" + elif [[ "$icon_name" == "Cloudy" ]]; then + echo "%{F#$WHITE}  %{F-}" + elif [[ "$icon_name" == "Overcast" ]]; then + echo "%{F#$BRIGHT_BLACK}  %{F-}" + elif [[ "$icon_name" == "Light snow shower day" ]]; then + echo "%{F#$WHITE}  %{F-}" + else + echo "%{F#$RED}  %{F-}" + fi + else + if [[ "$icon_name" == "Sunny day" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$YELLOW'>  </span>" + elif [[ "$icon_name" == "Light shower day" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$WHITE'>  </span>" + elif [[ "$icon_name" == "Sunny intervals" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$YELLOW'>  </span>" + elif [[ "$icon_name" == "Light rain" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$BRIGHT_BLACK'>  </span>" + elif [[ "$icon_name" == "Heavy rain" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$BLUE'>  </span>" + elif [[ "$icon_name" == "Cloudy" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$WHITE'>  </span>" + elif [[ "$icon_name" == "Overcast" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$BRIGHT_BLACK'>  </span>" + elif [[ "$icon_name" == "Light snow shower day" ]]; then + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$WHITE'>  </span>" + else + echo "<span font='Font Awesome 7 Free Solid 9' foreground='#$RED'>  </span>" + fi + fi +} + +if [[ "$1" == "--conky" ]]; then + echo "$(format "$2" conky)" +elif [[ "$1" == "--lemonbar" ]]; then + echo "$(format "$2" lemonbar)" +else + echo "$(format "$1")" +fi + +# moon rain  +# heavy showers +# snow  +# lightning  +# bolt  +# sun  +# moon  +# smog  +# tornado  +# cloud showers water  +# cloud moon  +# hurricane  +# water  +# wind  +# bolt lightning  +# umbrella  +# volcano  +# temperature half  +# temperature three quarters  +# temperature quarter  +# temperature low  +# temperature high  +# temperature full  +# temperature empty  +# temperature arrow up  +# temperature arrow down  +# sun plant wilt  +# rainbow  +# icicles  +# house tsunami  diff --git a/setup.sh b/setup.sh @@ -1,11 +1,11 @@ #!/bin/sh -file="$2" +file="lists/$2" exec 3<&0 if [ "$1" = "save" ]; then while read -r filepath; do - repo_path=$(echo "$filepath" | sed "s|~|dotfiles|g") + repo_path=$(echo "$filepath" | sed "s|~|$2|g") real_path=$(echo "$filepath" | sed "s|~|$HOME|g") basename=$(basename "$filepath") repo_dirname=$(dirname "$repo_path") @@ -20,7 +20,7 @@ if [ "$1" = "save" ]; then done < $file elif [ "$1" = "make" ]; then while read -r filepath; do - repo_path=$(echo "$filepath" | sed "s|~|dotfiles|g") + repo_path=$(echo "$filepath" | sed "s|~|$2|g") real_path=$(echo "$filepath" | sed "s|~|$HOME|g") basename=$(basename "$filepath") real_dirname=$(dirname "$real_path")