From 69ff91834fac0db773e2f601963d5bb8ead70154 Mon Sep 17 00:00:00 2001 From: jabuxas Date: Fri, 27 Sep 2024 13:23:11 -0300 Subject: [PATCH] feat: add white theme switch and go back to gentoo --- .../.config/alacritty/alacritty.toml | 32 +------------ .../.config/alacritty/solarized-dark.toml | 27 +++++++++++ .../alacritty/.config/alacritty/white.toml | 27 +++++++++++ desktop/configs/fish/.config/fish/config.fish | 7 ++- .../configs/fish/.config/fish/fish_variables | 2 +- .../functions/fish_command_not_found.fish | 16 +++---- .../configs/sway/.config/sway/settings/binds | 5 +- .../configs/sway/.config/sway/settings/init | 2 +- desktop/configs/tmux/.config/tmux/tmux.conf | 2 +- .../waybar/.config/waybar/style-white.css | 44 ++++++++++++++++++ .../base16/base16-default-dark.css | 0 .../waybar/{ => unused}/config-chinese | 0 .../waybar/{ => unused}/dwm-forest.css | 0 .../.config/waybar/{ => unused}/dwm.css | 0 .../.config/waybar/{ => unused}/dwm.jsonc | 0 .../waybar/.config/waybar/{ => unused}/state | Bin .../waybar/{ => unused}/style-melange.css | 0 .../{ => unused}/style-solarized-light.css | 0 .../waybar/{ => unused}/style-solarized.css | 0 .../waybar/{ => unused}/style.css.chinese | 0 desktop/scripts/switch.fish | 29 ++++++++++++ 21 files changed, 146 insertions(+), 47 deletions(-) create mode 100644 desktop/configs/alacritty/.config/alacritty/solarized-dark.toml create mode 100644 desktop/configs/alacritty/.config/alacritty/white.toml create mode 100644 desktop/configs/waybar/.config/waybar/style-white.css rename desktop/configs/waybar/.config/waybar/{ => unused}/base16/base16-default-dark.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/config-chinese (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/dwm-forest.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/dwm.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/dwm.jsonc (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/state (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/style-melange.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/style-solarized-light.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/style-solarized.css (100%) rename desktop/configs/waybar/.config/waybar/{ => unused}/style.css.chinese (100%) create mode 100755 desktop/scripts/switch.fish diff --git a/desktop/configs/alacritty/.config/alacritty/alacritty.toml b/desktop/configs/alacritty/.config/alacritty/alacritty.toml index aff7763..be205d5 100644 --- a/desktop/configs/alacritty/.config/alacritty/alacritty.toml +++ b/desktop/configs/alacritty/.config/alacritty/alacritty.toml @@ -12,13 +12,13 @@ # I put the file alacritty.toml in $HOME/.config/alacritty. However it can be kept anywhere among the places mentioned in # https://github.com/alacritty/alacritty/tree/master#configuration +import = ["~/.config/alacritty/white.toml"] + [window] # opacity = 0.9 - padding.x = 10 # padding.y = 10 - decorations = "Full" decorations_theme_variant = "Light" # "Dark" @@ -34,34 +34,6 @@ bold_italic.family = "CartographCF Nerd Font" bold_italic.style = "ExtraBold Italic" -[colors.primary] -background = "#002b36" -foreground = "#839496" - -[colors.normal] -black = '#073642' # Black (Host) -red = '#dc322f' # red (syntax string) -green = '#859900' # green (command) -yellow = '#b58900' # yellow (command second) -blue = '#268bd2' # blue (path) -magenta = '#d33682' # magenta (syntax var) -cyan = '#2aa198' # cyan (prompt) -white= '#eee8d5' # white - -[colors.bright] -black= '#002b36' # Bright Black -red = '#cb4b16' # bright red (command error) -green = '#586e75' # bright green (exec) -yellow= '#657b83' # bright yellow -blue = '#839496' # bright blue (folder) -magenta= '#6c71c4' # bright magenta -cyan= '#93a1a1' # bright cyan -white= '#fdf6e3' # bright white - -[colors.cursor] -text = "#002b36" -cursor = "#839496" - [[hints.enabled]] binding = { key = "O", mods = "Control|Shift" } command = "xdg-open" diff --git a/desktop/configs/alacritty/.config/alacritty/solarized-dark.toml b/desktop/configs/alacritty/.config/alacritty/solarized-dark.toml new file mode 100644 index 0000000..a87227a --- /dev/null +++ b/desktop/configs/alacritty/.config/alacritty/solarized-dark.toml @@ -0,0 +1,27 @@ +[colors.primary] +background = "#002b36" +foreground = "#839496" + +[colors.normal] +black = '#073642' # Black (Host) +red = '#dc322f' # red (syntax string) +green = '#859900' # green (command) +yellow = '#b58900' # yellow (command second) +blue = '#268bd2' # blue (path) +magenta = '#d33682' # magenta (syntax var) +cyan = '#2aa198' # cyan (prompt) +white= '#eee8d5' # white + +[colors.bright] +black= '#002b36' # Bright Black +red = '#cb4b16' # bright red (command error) +green = '#586e75' # bright green (exec) +yellow= '#657b83' # bright yellow +blue = '#839496' # bright blue (folder) +magenta= '#6c71c4' # bright magenta +cyan= '#93a1a1' # bright cyan +white= '#fdf6e3' # bright white + +[colors.cursor] +text = "#002b36" +cursor = "#839496" diff --git a/desktop/configs/alacritty/.config/alacritty/white.toml b/desktop/configs/alacritty/.config/alacritty/white.toml new file mode 100644 index 0000000..0a52df0 --- /dev/null +++ b/desktop/configs/alacritty/.config/alacritty/white.toml @@ -0,0 +1,27 @@ +[colors.normal] +black = '#EEE8D5' # Black (Host) +red = '#DC322F' # Red (Syntax string) +green = '#859900' # Green (Command) +yellow = '#b58900' # yellow (command second) +blue = '#268bd2' # blue (path) +magenta = '#d33682' # magenta (syntax var) +cyan = '#2aa198' # cyan (prompt) +white= '#002b36' # white + +[colors.bright] +black= '#657b83' # Bright Black +red = '#cb4b16' # bright red (command error) +green = '#859900' # bright green (exec) +yellow= '#b58900' # bright yellow +blue = '#6c71c4' # bright blue (folder) +magenta= '#d33682' # bright magenta +cyan= '#2aa198' # bright cyan +white= '#073642' # bright white + +[colors.primary] +background= '#FDF6E3' # Background +foreground= '#657B83' # Foreground (Text) + +[colors.cursor] +cursor= '#657b83' # cursor +text= '#FDF6E3' # Background diff --git a/desktop/configs/fish/.config/fish/config.fish b/desktop/configs/fish/.config/fish/config.fish index c2c7310..2463de0 100644 --- a/desktop/configs/fish/.config/fish/config.fish +++ b/desktop/configs/fish/.config/fish/config.fish @@ -4,7 +4,6 @@ if status --is-login set -gx BAT_THEME "Solarized (light)" set -gx EDITOR "nvim" - set -gx DOCKER_HOST unix://$XDG_RUNTIME_DIR/podman/podman.sock if test -z "$WAYLAND_DISPLAY" && test "$XDG_VTNR" -eq 1 set -gx XDG_CURRENT_DESKTOP "sway" @@ -17,15 +16,15 @@ if status is-interactive alias ls="bash ~/scripts/elash.sh" alias l="ls -lah" alias v="nvim" - alias reboot="loginctl reboot" + alias reboot="systemctl reboot" alias hr="date +'%Hh:%M, %d-%m-%Y'" - alias hi="loginctl hibernate" + alias hi="systemctl hibernate" alias ff="fastfetch" alias feh="imv" alias lg="lazygit" alias cpr="cd ~/repos/cports-docker && docker compose run --build --rm cports" alias cop="wl-copy" - alias poweroff="loginctl poweroff" + alias poweroff="systemctl poweroff" alias cat="bat" end diff --git a/desktop/configs/fish/.config/fish/fish_variables b/desktop/configs/fish/.config/fish/fish_variables index 608307c..75cb99d 100644 --- a/desktop/configs/fish/.config/fish/fish_variables +++ b/desktop/configs/fish/.config/fish/fish_variables @@ -26,7 +26,7 @@ SETUVAR fish_color_selection:white\x1e\x2d\x2dbold\x1e\x2d\x2dbackground\x3dbrbl SETUVAR fish_color_status:red SETUVAR fish_color_user:brgreen SETUVAR fish_color_valid_path:\x2d\x2dunderline -SETUVAR fish_key_bindings:fish_default_key_bindings +SETUVAR fish_key_bindings:fish_vi_key_bindings SETUVAR fish_pager_color_background:\x1d SETUVAR fish_pager_color_completion:B3A06D SETUVAR fish_pager_color_description:B3A06D diff --git a/desktop/configs/fish/.config/fish/functions/fish_command_not_found.fish b/desktop/configs/fish/.config/fish/functions/fish_command_not_found.fish index 275b786..2b70a29 100644 --- a/desktop/configs/fish/.config/fish/functions/fish_command_not_found.fish +++ b/desktop/configs/fish/.config/fish/functions/fish_command_not_found.fish @@ -1,8 +1,8 @@ -function fish_command_not_found - set -l pkgs (apk search --quiet cmd:$argv[1]) - set pkgs (string join '|' $pkgs) - echo "$argv[1]: not found" - if test -n "$pkgs" - echo " install with: apk add $pkgs" - end -end +# function fish_command_not_found +# set -l pkgs (apk search --quiet cmd:$argv[1]) +# set pkgs (string join '|' $pkgs) +# echo "$argv[1]: not found" +# if test -n "$pkgs" +# echo " install with: apk add $pkgs" +# end +# end diff --git a/desktop/configs/sway/.config/sway/settings/binds b/desktop/configs/sway/.config/sway/settings/binds index 38bf7d9..2f3f576 100644 --- a/desktop/configs/sway/.config/sway/settings/binds +++ b/desktop/configs/sway/.config/sway/settings/binds @@ -16,7 +16,8 @@ mode "resize" { } bindsym $mod+r mode "resize" -bindsym $mod+b exec firefox +bindsym $mod+b exec firefox-bin +bindsym $mod+Shift+apostrophe exec ~/scripts/switch.fish bindsym $mod+Shift+b exec qutebrowser bindsym $mod+Shift+d exec flatpak run de.shorsh.discord-screenaudio bindsym $mod+Return exec $term @@ -79,7 +80,7 @@ bindsym $mod+Control+Return move scratchpad # If there are multiple scratchpad windows, this command cycles through them. bindsym $mod+Control+s scratchpad show -bindsym $mod+Shift+s exec flatpak run com.valvesoftware.Steam --noverifyfiles +bindsym $mod+Shift+s exec steam bindsym $mod+e exec pcmanfm bindsym Print exec ~/.local/bin/way-print p bindsym Shift+Print exec ~/.local/bin/way-print.sh s diff --git a/desktop/configs/sway/.config/sway/settings/init b/desktop/configs/sway/.config/sway/settings/init index e44059a..e2569b2 100644 --- a/desktop/configs/sway/.config/sway/settings/init +++ b/desktop/configs/sway/.config/sway/settings/init @@ -10,7 +10,7 @@ exec { xrandr --output HDMI-A-1 --primary waybar & autotiling & - gammastep -t 4500:3500 -l -23.5475:-46.63611 -b 1.0:0.6 & + gammastep -t 4500:3500 -l -23.5475:-46.63611 -b 1.0:0.7 & dbus-update-activation-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway DISPLAY rm -rf ~/tmp/* ~/scripts/swww.sh diff --git a/desktop/configs/tmux/.config/tmux/tmux.conf b/desktop/configs/tmux/.config/tmux/tmux.conf index 268722d..275ad59 100644 --- a/desktop/configs/tmux/.config/tmux/tmux.conf +++ b/desktop/configs/tmux/.config/tmux/tmux.conf @@ -76,7 +76,7 @@ source ~/.config/tmux/theme.conf set -g visual-bell off set -as terminal-overrides ',*:Smulx=\E[4::%p1%dm' # undercurl support set -as terminal-overrides ',*:Setulc=\E[58::2::%p1%{65536}%/%d::%p1%{256}%/%{255}%&%d::%p1%{255}%&%d%;m' # underscore colours - needs tmux-3.0 -set -g status-position top +set -g status-position bottom set -g default-terminal "tmux-256color" set -sg terminal-overrides ",*:RGB" diff --git a/desktop/configs/waybar/.config/waybar/style-white.css b/desktop/configs/waybar/.config/waybar/style-white.css new file mode 100644 index 0000000..77f6c2e --- /dev/null +++ b/desktop/configs/waybar/.config/waybar/style-white.css @@ -0,0 +1,44 @@ +* { + border: none; + border-radius: 0; + /* padding: 0; */ + /* margin: 0; */ + font-size: 18px; + font-family: UbuntuMono Nerd Font Mono; + font-style: italic; +} + +window#waybar { + background: #fdf6e3; + color: #000; + margin: 10px; +} + +#workspaces button { + margin-left: 2px; + padding: 2px 8px; + color: #000; +} + +#workspaces button:hover, +#workspaces button:active { + background-color: #004d61; + color: #000; +} + +#workspaces button.focused { + background-color: #eee8d5; +} + +#language { + margin-right: 7px; +} + +#battery { + margin-left: 7px; + margin-right: 3px; +} + +#clock { + margin: 0px 6px; +} diff --git a/desktop/configs/waybar/.config/waybar/base16/base16-default-dark.css b/desktop/configs/waybar/.config/waybar/unused/base16/base16-default-dark.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/base16/base16-default-dark.css rename to desktop/configs/waybar/.config/waybar/unused/base16/base16-default-dark.css diff --git a/desktop/configs/waybar/.config/waybar/config-chinese b/desktop/configs/waybar/.config/waybar/unused/config-chinese similarity index 100% rename from desktop/configs/waybar/.config/waybar/config-chinese rename to desktop/configs/waybar/.config/waybar/unused/config-chinese diff --git a/desktop/configs/waybar/.config/waybar/dwm-forest.css b/desktop/configs/waybar/.config/waybar/unused/dwm-forest.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/dwm-forest.css rename to desktop/configs/waybar/.config/waybar/unused/dwm-forest.css diff --git a/desktop/configs/waybar/.config/waybar/dwm.css b/desktop/configs/waybar/.config/waybar/unused/dwm.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/dwm.css rename to desktop/configs/waybar/.config/waybar/unused/dwm.css diff --git a/desktop/configs/waybar/.config/waybar/dwm.jsonc b/desktop/configs/waybar/.config/waybar/unused/dwm.jsonc similarity index 100% rename from desktop/configs/waybar/.config/waybar/dwm.jsonc rename to desktop/configs/waybar/.config/waybar/unused/dwm.jsonc diff --git a/desktop/configs/waybar/.config/waybar/state b/desktop/configs/waybar/.config/waybar/unused/state similarity index 100% rename from desktop/configs/waybar/.config/waybar/state rename to desktop/configs/waybar/.config/waybar/unused/state diff --git a/desktop/configs/waybar/.config/waybar/style-melange.css b/desktop/configs/waybar/.config/waybar/unused/style-melange.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/style-melange.css rename to desktop/configs/waybar/.config/waybar/unused/style-melange.css diff --git a/desktop/configs/waybar/.config/waybar/style-solarized-light.css b/desktop/configs/waybar/.config/waybar/unused/style-solarized-light.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/style-solarized-light.css rename to desktop/configs/waybar/.config/waybar/unused/style-solarized-light.css diff --git a/desktop/configs/waybar/.config/waybar/style-solarized.css b/desktop/configs/waybar/.config/waybar/unused/style-solarized.css similarity index 100% rename from desktop/configs/waybar/.config/waybar/style-solarized.css rename to desktop/configs/waybar/.config/waybar/unused/style-solarized.css diff --git a/desktop/configs/waybar/.config/waybar/style.css.chinese b/desktop/configs/waybar/.config/waybar/unused/style.css.chinese similarity index 100% rename from desktop/configs/waybar/.config/waybar/style.css.chinese rename to desktop/configs/waybar/.config/waybar/unused/style.css.chinese diff --git a/desktop/scripts/switch.fish b/desktop/scripts/switch.fish new file mode 100755 index 0000000..bbec4cb --- /dev/null +++ b/desktop/scripts/switch.fish @@ -0,0 +1,29 @@ +#!/usr/bin/env fish +set CURRENT_THEME (cat ~/colorscheme) +echo $CURRENT_THEME + +set wpp1_white ~/pics/wallpapers/sl3.jpg +set wpp2_white ~/pics/wallpapers/sl2.png + +set wpp1_solarized ~/pics/wallpapers/sl6.jpg +set wpp2_solarized ~/pics/wallpapers/sl7.jpg + + +switch $CURRENT_THEME + case solarized + echo changing to white ... + sed -i 's|solarized-dark.toml|white.toml|' ~/.config/alacritty/alacritty.toml + pkill waybar; waybar -s ~/.config/waybar/style-white.css &> /dev/null & disown + ~/scripts/swww.sh $wpp1_white $wpp2_white + echo white > ~/colorscheme + case white + echo changing to solarized ... + sed -i 's|white.toml|solarized-dark.toml|' ~/.config/alacritty/alacritty.toml + pkill waybar; waybar &> /dev/null & disown + ~/scripts/swww.sh $wpp1_solarized $wpp2_solarized + echo solarized > ~/colorscheme + case '*' + echo mmmm what? +end + +swaymsg reload