diff --git a/.gitignore b/.gitignore index 85e277f..db4f6fb 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ **/.pre-commit-config.yaml **/result /.direnv +/.ruff_cache diff --git a/hosts/python/configs/kitty/current-theme.conf b/hosts/python/configs/kitty/current-theme.conf index 369da8d..e89c8fa 100644 --- a/hosts/python/configs/kitty/current-theme.conf +++ b/hosts/python/configs/kitty/current-theme.conf @@ -1,49 +1,104 @@ -# gruvbox dark by morhetz, https://github.com/morhetz/gruvbox -# This work is licensed under the terms of the MIT license. -# For a copy, see https://opensource.org/licenses/MIT. +# vim:ft=kitty +## name: Carbonfox +## author: EdenEast +## license: MIT +## upstream: https://github.com/EdenEast/nightfox.nvim/blob/main/extra/carbonfox/kitty.conf +## blurb: Carbonfox theme from the neovim colorscheme nightfox.nvim. -background #282828 -foreground #ebdbb2 +#: All the settings below are colors, which you can choose to modify, or use the +#: defaults. You can also add non-color based settings if needed but note that +#: these will not work with using kitty @ set-colors with this theme. For a +#: reference on what these settings do see https://sw.kovidgoyal.net/kitty/conf/ -cursor #928374 +#: The basic colors -selection_foreground #928374 -selection_background #3c3836 +foreground #f2f4f8 +background #161616 +selection_foreground #f2f4f8 +selection_background #2a2a2a -color0 #282828 -color8 #928374 -# red -color1 #cc241d -# light red -color9 #fb4934 +#: Cursor colors -# green -color2 #98971a -# light green -color10 #b8bb26 +cursor #f2f4f8 +cursor_text_color #161616 -# yellow -color3 #d79921 -# light yellow -color11 #fabd2d -# blue -color4 #458588 -# light blue -color12 #83a598 +#: URL underline color when hovering with mouse -# magenta -color5 #b16286 -# light magenta -color13 #d3869b +url_color #25be6a -# cyan -color6 #689d6a -# lighy cyan -color14 #8ec07c -# light gray -color7 #a89984 -# dark gray -color15 #928374 +#: kitty window border colors and terminal bell colors + +active_border_color #78a9ff +inactive_border_color #535353 +bell_border_color #3ddbd9 +# visual_bell_color none + + +#: OS Window titlebar colors + +# wayland_titlebar_color system +# macos_titlebar_color system + + +#: Tab bar colors + +active_tab_foreground #0c0c0c +active_tab_background #78a9ff +inactive_tab_foreground #6e6f70 +inactive_tab_background #2a2a2a +# tab_bar_background none +# tab_bar_margin_color none + + +#: Colors for marks (marked text in the terminal) + +# mark1_foreground black +# mark1_background #98d3cb +# mark2_foreground black +# mark2_background #f2dcd3 +# mark3_foreground black +# mark3_background #f274bc + + +#: The basic 16 colors + +#: black +color0 #282828 +color8 #484848 + +#: red +color1 #ee5396 +color9 #f16da6 + +#: green +color2 #25be6a +color10 #46c880 + +#: yellow +color3 #ebcb8b +color11 #f0d399 + +#: blue +color4 #78a9ff +color12 #8cb6ff + +#: magenta +color5 #be95ff +color13 #c8a5ff + +#: cyan +color6 #33b1ff +color14 #52bdff + +#: white +color7 #dfdfe0 +color15 #e4e4e5 + + +#: You can set the remaining 240 colors as color16 to color255. + +color16 #3ddbd9 +color17 #ff7eb6 diff --git a/hosts/python/configs/river/init b/hosts/python/configs/river/init index 7f0f49a..3ca2a42 100755 --- a/hosts/python/configs/river/init +++ b/hosts/python/configs/river/init @@ -1,66 +1,69 @@ #!/bin/sh +mod="Super" + riverctl spawn kanshi -riverctl spawn "wbg $HOME/.local/share/wallpapers/01.jpg" +riverctl spawn "wbg $HOME/.local/share/wallpapers/07.jpg" riverctl spawn "waybar" riverctl spawn "systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" riverctl spawn "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river" -riverctl map normal Super+Shift Return spawn kitty -riverctl map normal Super P spawn "rofi -show drun" -riverctl map normal Super Q close -riverctl map normal Super+Shift E exit -riverctl map normal Super+Shift C spawn "$HOME/.config/river/init" -riverctl map normal Super J focus-view next -riverctl map normal Super K focus-view previous -riverctl map normal Super+Shift J swap next -riverctl map normal Super+Shift K swap previous -riverctl map normal Super Period focus-output next -riverctl map normal Super Comma focus-output previous -riverctl map normal Super+Shift Period send-to-output next -riverctl map normal Super+Shift Comma send-to-output previous -riverctl map normal Super Return zoom -riverctl map normal Super H send-layout-cmd rivertile "main-ratio -0.05" -riverctl map normal Super L send-layout-cmd rivertile "main-ratio +0.05" -riverctl map normal Super+Shift H send-layout-cmd rivertile "main-count +1" -riverctl map normal Super+Shift L send-layout-cmd rivertile "main-count -1" -riverctl map normal Super+Alt H move left 100 -riverctl map normal Super+Alt J move down 100 -riverctl map normal Super+Alt K move up 100 -riverctl map normal Super+Alt L move right 100 -riverctl map normal Super+Alt+Control H snap left -riverctl map normal Super+Alt+Control J snap down -riverctl map normal Super+Alt+Control K snap up -riverctl map normal Super+Alt+Control L snap right -riverctl map normal Super+Alt+Shift H resize horizontal -100 -riverctl map normal Super+Alt+Shift J resize vertical 100 -riverctl map normal Super+Alt+Shift K resize vertical -100 -riverctl map normal Super+Alt+Shift L resize horizontal 100 -riverctl map-pointer normal Super BTN_LEFT move-view -riverctl map-pointer normal Super BTN_RIGHT resize-view -riverctl map-pointer normal Super BTN_MIDDLE toggle-float +riverctl map normal "$mod"+Shift Return spawn kitty +riverctl map normal "$mod" P spawn "rofi -show drun" +riverctl map normal "$mod" S spawn "$HOME/.config/river/scripts/screenshot.sh savecopy" +riverctl map normal "$mod" Q close +riverctl map normal "$mod"+Shift E exit +riverctl map normal "$mod"+Shift C spawn "$HOME/.config/river/init" +riverctl map normal "$mod" J focus-view next +riverctl map normal "$mod" K focus-view previous +riverctl map normal "$mod"+Shift J swap next +riverctl map normal "$mod"+Shift K swap previous +riverctl map normal "$mod" Period focus-output next +riverctl map normal "$mod" Comma focus-output previous +riverctl map normal "$mod"+Shift Period send-to-output next +riverctl map normal "$mod"+Shift Comma send-to-output previous +riverctl map normal "$mod" Return zoom +riverctl map normal "$mod" H send-layout-cmd rivercarro "main-ratio -0.05" +riverctl map normal "$mod" L send-layout-cmd rivercarro "main-ratio +0.05" +riverctl map normal "$mod"+Shift H send-layout-cmd rivercarro "main-count +1" +riverctl map normal "$mod"+Shift L send-layout-cmd rivercarro "main-count -1" +riverctl map normal "$mod"+Alt H move left 100 +riverctl map normal "$mod"+Alt J move down 100 +riverctl map normal "$mod"+Alt K move up 100 +riverctl map normal "$mod"+Alt L move right 100 +riverctl map normal "$mod"+Alt+Control H snap left +riverctl map normal "$mod"+Alt+Control J snap down +riverctl map normal "$mod"+Alt+Control K snap up +riverctl map normal "$mod"+Alt+Control L snap right +riverctl map normal "$mod"+Alt+Shift H resize horizontal -100 +riverctl map normal "$mod"+Alt+Shift J resize vertical 100 +riverctl map normal "$mod"+Alt+Shift K resize vertical -100 +riverctl map normal "$mod"+Alt+Shift L resize horizontal 100 +riverctl map-pointer normal "$mod" BTN_LEFT move-view +riverctl map-pointer normal "$mod" BTN_RIGHT resize-view +riverctl map-pointer normal "$mod" BTN_MIDDLE toggle-float for i in $(seq 1 9); do tags=$((1 << (i - 1))) - riverctl map normal Super "$i" set-focused-tags "$tags" - riverctl map normal Super+Shift "$i" set-view-tags "$tags" - riverctl map normal Super+Control "$i" toggle-focused-tags "$tags" - riverctl map normal Super+Shift+Control "$i" toggle-view-tags "$tags" + riverctl map normal "$mod" "$i" set-focused-tags "$tags" + riverctl map normal "$mod"+Shift "$i" set-view-tags "$tags" + riverctl map normal "$mod"+Control "$i" toggle-focused-tags "$tags" + riverctl map normal "$mod"+Shift+Control "$i" toggle-view-tags "$tags" done all_tags=$(((1 << 32) - 1)) -riverctl map normal Super 0 set-focused-tags "$all_tags" -riverctl map normal Super+Shift 0 set-view-tags "$all_tags" -riverctl map normal Super Space toggle-float -riverctl map normal Super F toggle-fullscreen -riverctl map normal Super Up send-layout-cmd rivertile "main-location top" -riverctl map normal Super Right send-layout-cmd rivertile "main-location right" -riverctl map normal Super Down send-layout-cmd rivertile "main-location bottom" -riverctl map normal Super Left send-layout-cmd rivertile "main-location left" +riverctl map normal "$mod" 0 set-focused-tags "$all_tags" +riverctl map normal "$mod"+Shift 0 set-view-tags "$all_tags" +riverctl map normal "$mod" Space toggle-float +riverctl map normal "$mod" F toggle-fullscreen +riverctl map normal "$mod" Up send-layout-cmd rivercarro "main-location top" +riverctl map normal "$mod" Right send-layout-cmd rivercarro "main-location right" +riverctl map normal "$mod" Down send-layout-cmd rivercarro "main-location bottom" +riverctl map normal "$mod" Left send-layout-cmd rivercarro "main-location left" riverctl declare-mode passthrough -riverctl map normal Super F11 enter-mode passthrough -riverctl map passthrough Super F11 enter-mode normal +riverctl map normal "$mod" F11 enter-mode passthrough +riverctl map passthrough "$mod" F11 enter-mode normal for mode in normal locked; do riverctl map "$mode" None XF86Eject spawn 'eject -T' @@ -79,7 +82,7 @@ done riverctl rule-add ssd riverctl background-color 0x00000000 -riverctl border-color-focused 0x8ec07cff +riverctl border-color-focused 0xbe95ffff riverctl border-color-unfocused 0x00000000 riverctl keyboard-layout "us" @@ -87,5 +90,5 @@ riverctl set-repeat 50 300 riverctl xcursor-theme "Simp1e-Gruvbox-Dark" -riverctl default-layout rivertile -rivertile -view-padding 4 -outer-padding 4 & +riverctl default-layout rivercarro +rivercarro -inner-gaps 4 -outer-gaps 6 -no-smart-gaps & diff --git a/hosts/python/configs/river/scripts/screenshot.sh b/hosts/python/configs/river/scripts/screenshot.sh new file mode 100755 index 0000000..b231a95 --- /dev/null +++ b/hosts/python/configs/river/scripts/screenshot.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +# shellcheck disable=SC1091 +source "$HOME/.config/user-dirs.dirs" + +case "$1" in +"copy") + GEOM="$(slurp)" + if [ "$GEOM" == "" ]; then + grim - | wl-copy + else + grim -g "$GEOM" - | wl-copy + fi + echo "Screenshot copied." + ;; +"save") + GEOM="$(slurp)" + if [ "$GEOM" == "" ]; then + grim "$OUT" + else + grim -g "$GEOM" "$OUT" + fi + echo "Screenshot saved. $OUT" + ;; +"savecopy") + GEOM="$(slurp)" + if [ "$GEOM" == "" ]; then + grim - | wl-copy + else + grim -g "$GEOM" - | wl-copy + fi + wl-copy <"$OUT" + echo "Screenshot saved and copied. $OUT" + ;; +*) + echo "Not done!" + ;; +esac diff --git a/hosts/python/configs/waybar/style.css b/hosts/python/configs/waybar/style.css index b910860..9b51f79 100644 --- a/hosts/python/configs/waybar/style.css +++ b/hosts/python/configs/waybar/style.css @@ -1,25 +1,25 @@ * { all: unset; font-size: 18px; - color: #ebdbb2; + color: #f2f4f8; } window#waybar { - background: #282828; + background: #0c0c0c; } tooltip { - background: #3c3836; + background: #161616; } .modules-left, .modules-right { - background: #3c3836; + background: #161616; padding: 0px 12px; } .modules-center { - background: #3c3836; + background: #161616; } #tags button { @@ -32,5 +32,5 @@ tooltip { } #tags button.focused { - background: #504945; + background: #282828; } diff --git a/hosts/python/theme.nix b/hosts/python/theme.nix index 9285583..fe7d809 100644 --- a/hosts/python/theme.nix +++ b/hosts/python/theme.nix @@ -4,11 +4,16 @@ ... }: let themes = { - gtk-theme = pkgs.gruvbox-material-gtk-theme; + gtk-theme = pkgs.nightfox-gtk-theme.override { + colorVariants = ["dark"]; + tweakVariants = ["carbon"]; + sizeVariants = ["compact"]; + themeVariants = ["all"]; + }; kvantum-theme = pkgs.gruvbox-kvantum.override { variant = "Gruvbox-Dark-Green"; }; - icon-theme = pkgs.gruvbox-plus-icons; + icon-theme = pkgs.colloid-icon-theme; cursor-theme = pkgs.simp1e-cursors; }; in { @@ -19,9 +24,9 @@ in { "org/gnome/desktop/interface" = { color-scheme = "prefer-dark"; cursor-size = lib.gvariant.mkUint32 24; - cursor-theme = "Simp1e-Gruvbox-Dark"; - icon-theme = "Gruvbox-Plus-Dark"; - gtk-theme = "Gruvbox-Material-Dark"; + cursor-theme = "Simp1e-Dark"; + icon-theme = "Colloid-Dark"; + gtk-theme = "Nightfox-Purple-Dark-Compact-Carbon"; }; }; } @@ -31,14 +36,15 @@ in { qt = { enable = true; - platformTheme = "qt5ct"; - style = "kvantum"; + platformTheme = "gnome"; + style = "adwaita-dark"; }; environment.systemPackages = builtins.attrValues themes; systemd.user.tmpfiles.rules = [ - "L+ %h/.config/gtk-4.0/gtk.css - - - - ${themes.gtk-theme}/share/themes/Gruvbox-Material-Dark/gtk-4.0/gtk.css" - "L+ %h/.config/gtk-4.0/assets - - - - ${themes.gtk-theme}/share/themes/Gruvbox-Material-Dark/gtk-4.0/assets" + "L+ %h/.config/gtk-4.0/gtk.css - - - - ${themes.gtk-theme}/share/themes/Nightfox-Purple-Dark-Compact-Carbon/gtk-4.0/gtk.css" + "L+ %h/.config/gtk-4.0/gtk-dark.css - - - - ${themes.gtk-theme}/share/themes/Nightfox-Purple-Dark-Compact-Carbon/gtk-4.0/gtk-dark.css" + "L+ %h/.config/gtk-4.0/assets - - - - ${themes.gtk-theme}/share/themes/Nightfox-Purple-Dark-Compact-Carbon/gtk-4.0/assets" "L+ %h/.config/Kvantum/Gruvbox-Dark-Green - - - - ${themes.kvantum-theme}/share/Kvantum/Gruvbox-Dark-Green/" ]; } diff --git a/hosts/python/users.nix b/hosts/python/users.nix index 7c1dd0c..3c8d7f7 100644 --- a/hosts/python/users.nix +++ b/hosts/python/users.nix @@ -12,7 +12,7 @@ ".config/river/" = ./configs/river; ".config/kitty/" = ./configs/kitty; ".config/waybar/" = ./configs/waybar; - ".local/share/wallpapers" = "${inputs.wallpkgs.packages.${pkgs.system}.gruvbox}/share/wallpapers/gruvbox"; + ".local/share/wallpapers" = "${inputs.wallpkgs.packages.${pkgs.system}.nature}/share/wallpapers/nature"; }; packages = builtins.attrValues { inherit diff --git a/hosts/shared/river.nix b/hosts/shared/river.nix index 601aa1c..8e47997 100644 --- a/hosts/shared/river.nix +++ b/hosts/shared/river.nix @@ -19,6 +19,7 @@ in { extraPackages = [ pkgs.wbg pkgs.kanshi + pkgs.rivercarro ]; }; diff --git a/repl-result-out b/repl-result-out new file mode 120000 index 0000000..88c1efe --- /dev/null +++ b/repl-result-out @@ -0,0 +1 @@ +/nix/store/sdfrhzarlvm3w7j7x8zdaf5pcl1iiinr-nightfox-gtk-theme-0-unstable-2024-11-06 \ No newline at end of file