by roundabout, Sunday, 11 March 2018, 07:48:48 (1520754528), pushed by roundabout, Sunday, 11 May 2025, 13:22:21 (1746969741)
Author identity: nana-4 <nana-4@users.noreply.github.com>
eb83b0da0ee39c0978542d0d316a8ecac41c70ec
change_color.sh
@@ -137,85 +137,22 @@ echo "== Converting theme into template..."
for FILEPATH in "${PATHLIST[@]}"; do
find "${FILEPATH}" -type f -not -name '_color-palette.scss' -exec sed -i'' \
-e 's/^\(\$dark_fg_color:\).*$.*;.*$/\1 %FG%;/g' \
-e 's/^\(\$light_fg_color:\).*$.*;.*$/\1 %BG%;/g' \
\
-e 's/^\(\$fg_color:\).*$.*;.*$/\1 %FG%;/g' \
-e 's/^\(\$button_fg_color:\).*$.*;.*$/\1 %BTN_FG%;/g' \
-e 's/^\(\$secondary_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%BTN_FG%\2%BTN_FG%\3/g' \
-e 's/^\(\$hint_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%FG%\2%FG%\3/g' \
-e 's/^\(\$disabled_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%FG%\2%FG%\3/g' \
-e 's/^\(\$disabled_secondary_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%BTN_FG%\2%BTN_FG%\3/g' \
-e 's/^\(\$track_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%FG%\2%FG%\3/g' \
-e 's/^\(\$divider_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%FG%\2%FG%\3/g' \
\
-e 's/^\(\$titlebar_fg_color:\).*;.*$/\1 %MENU_FG%;/g' \
-e 's/^\(\$titlebar_secondary_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
-e 's/^\(\$titlebar_hint_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
-e 's/^\(\$titlebar_disabled_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
-e 's/^\(\$titlebar_disabled_secondary_fg_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
-e 's/^\(\$titlebar_track_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
-e 's/^\(\$titlebar_divider_color:.*\)\$black\(.*\)\$white\(.*\)$/\1%MENU_FG%\2%MENU_FG%\3/g' \
\
-e 's/^\(\$inverse_fg_color:\).*$.*;.*$/\1 %SEL_FG%;/g' \
-e 's/^\(\$inverse_secondary_fg_color:.*\)$white\(.*\)$/\1%SEL_FG%\2/g' \
-e 's/^\(\$inverse_hint_fg_color:.*\)\$white\(.*\)$/\1%SEL_FG%\2/g' \
-e 's/^\(\$inverse_disabled_fg_color:.*\)\$white\(.*\)$/\1%SEL_FG%\2/g' \
-e 's/^\(\$inverse_disabled_secondary_fg_color:.*\)\$white\(.*\)$/\1%SEL_FG%\2/g' \
-e 's/^\(\$inverse_track_color:.*\)\$white\(.*\)$/\1%SEL_FG%\2/g' \
-e 's/^\(\$inverse_divider_color:.*\)\$white\(.*\)$/\1%SEL_FG%\2/g' \
\
-e 's/^\(\$bg_color:.*\$variant.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%BG%\2%MENU_BG%\3/g' \
-e 's/^\(\$base_color:.*\$variant.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%TXT_BG%\2%MENU_BG%\3/g' \
-e 's/^\(\$alt_base_color:.*\$variant.*\)\$\w\+\(.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%INACTIVE_TXT_BG%\2%INACTIVE_TXT_BG%\3%MENU_BG%\4/g' \
-e 's/^\(\$lighter_bg_color:.*\$variant.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%BTN_BG%\2%BTN_BG%\3/g' \
-e 's/^\(\$darker_bg_color:.*\$variant.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%BG%\2%MENU_BG%\3/g' \
\
-e 's/^\(\$titlebar_bg_color:\).*;.*$/\1 %MENU_BG%;/g' \
-e 's/^\(\$alt_titlebar_bg_color:.*\$titlebar.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%MENU_BG%\2%MENU_BG%\3/g' \
-e 's/^\(\$panel_bg_color:.*\)$black\(.*\)$middle_opacity\(.*\)$/\1%MENU_BG%\2%GNOME_SHELL_PANEL_OPACITY%\3/g' \
-e 's/^\(\$solid_panel_bg_color:.*\$titlebar.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%MENU_BG%\2%MENU_BG%\3/g' \
-e 's/^\(\$opaque_panel_bg_color:.*\$titlebar.*\)\$\w\+\(.*\)\$\w\+\(.*\)\$\w\+\(.*\)$/\1%MENU_BG%\2%MENU_BG%\3%MENU_BG%\4/g' \
-e 's/^\(\$alt_panel_bg_color:.*\)$black\(.*\)$/\1%MENU_BG%\2/g' \
\
-e 's/^\(\$primary_color:\).*;.*$/\1 %SEL_BG%;/g' \
-e 's/^\(\$alt_primary_color:\).*;.*$/\1 %SEL_BG2%;/g' \
-e 's/^\(\$accent_color:\).*;.*$/\1 %ACCENT_BG%;/g' \
\
-e 's/^\(\$titlebar_highlight_color:\).*;.*$/\1 %MENU_BG%;/g' \
\
-e 's/$black/%FG%/g' \
-e 's/#000000/%FG%/g' \
-e 's/$grey_900/%FG%/g' \
-e 's/#212121/%FG%/g' \
-e 's/$grey_500/%INACTIVE_FG%/g' \
-e 's/#757575/%INACTIVE_FG%/g' \
-e 's/#9E9E9E/%INACTIVE_FG%/g' \
-e 's/#c3c8ca/%INACTIVE_FG%/g' \
-e 's/$grey_400/%MENU_BG2%/g' \
-e 's/#BDBDBD/%MENU_BG2%/g' \
-e 's/$grey_300/%SEL_BG%/g' \
-e 's/#E0E0E0/%SEL_BG%/g' \
-e 's/$grey_200/%BG2%/g' \
-e 's/$grey_100/%BG%/g' \
-e 's/#F5F5F5/%BG%/g' \
-e 's/$grey_50/%BTN_BG%/g' \
-e 's/#FAFAFA/%BTN_BG%/g' \
-e 's/$pink_A200/%ACCENT_BG%/g' \
-e 's/#FF4081/%ACCENT_BG%/g' \
-e 's/$blue_400/%SEL_BG%/g' \
-e 's/#42A5F5/%SEL_BG%/g' \
-e 's/$light_blue_A200/%SEL_BG2%/g' \
-e 's/$white/%TXT_BG%/g' \
-e 's/#FFFFFF/%TXT_BG%/g' \
-e 's/$blue_grey_700/%MENU_BG%/g' \
-e 's/$blue_grey_600/%MENU_BG%/g' \
-e 's/#333e43/%MENU_BG%/g' \
-e 's/#455A64/%MENU_BG%/g' \
-e 's/#37474F/%MENU_BG%/g' \
-e 's/$blue_grey_800/%MENU_BG2%/g' \
-e 's/#3b484e/%MENU_BG2%/g' \
-e 's/$blue_grey_900/%MENU_BG3%/g' \
-e 's/#414f56/%MENU_BG3%/g' \
-e 's/Materia/%OUTPUT_THEME_NAME%/g' \
{} \; ;