diff --git a/STYLIX_MIGRATION_WORK.md b/STYLIX_MIGRATION_WORK.md new file mode 100644 index 0000000..b79c087 --- /dev/null +++ b/STYLIX_MIGRATION_WORK.md @@ -0,0 +1,174 @@ +# Stylix Migration Work - COMPLETED + +## Summary of Work Completed + +### 1. Replaced Catppuccin with Stylix +- Removed `catppuccin` input from `flake.nix` +- Added `stylix` input (release-25.11 branch to match NixOS version) +- Added `stylix.nixosModules.stylix` to frame12 modules in flake.nix +- Removed catppuccin modules from nate, nate-work, and frame12 configurations + +### 2. Stylix Configuration +**File: `/home/nate/nixos/frame12/default.nix`** +```nix +stylix = { + enable = true; + image = ./wallpaper.png; + base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml"; + polarity = "dark"; + + # System-wide cursor + cursor = { + package = pkgs.bibata-cursors; + name = "Bibata-Modern-Classic"; + size = 32; + }; + + # Fonts + fonts = { + serif = { package = pkgs.lato; name = "Lato"; }; + sansSerif = { package = pkgs.lato; name = "Lato"; }; + monospace = { package = pkgs.maple-mono.NF; name = "Maple Mono NF"; }; + emoji = { package = pkgs.noto-fonts-color-emoji; name = "Noto Color Emoji"; }; + sizes = { + applications = 12; + desktop = 10; + popups = 10; + terminal = 11; + }; + }; + + targets.plymouth.enable = false; # Keep custom Framework plymouth theme +}; +``` + +### 3. Stylix Auto-Enable in Home Manager +**File: `/home/nate/nixos/frame12/modules/home-manager/home.nix`** +- Enabled `stylix.autoEnable = true` for automatic theming of all programs + +### 4. Programs Converted to Nix Configuration + +All programs below now use `programs..enable = true` with Stylix auto-theming: + +**File: `/home/nate/nixos/frame12/modules/home-manager/programs.nix`** +| Program | Status | Notes | +|---------|--------|-------| +| Ghostty | DONE | Maple Mono NF with ligatures, keybinds | +| Foot | DONE | Minimal config, Stylix handles fonts/colors | +| Helix | DONE | Full config with Colemak-DH bindings, languages, LSP | +| Bat | DONE | Simple enable | +| Fzf | DONE | With zsh integration | +| Btop | DONE | Simple enable | +| Mpv | DONE | Simple enable | +| Wofi | DONE | Simple enable | + +**File: `/home/nate/nixos/shared/modules/home-manager/waybar.nix`** +| Program | Status | Notes | +|---------|--------|-------| +| Waybar | DONE | Shared module with parameterized options | + +### 5. Waybar Shared Module + +Created parameterized waybar module for use across multiple machines: +- **File**: `/home/nate/nixos/shared/modules/home-manager/waybar.nix` +- **Options**: + - `waybarConfig.enable` - Enable waybar with Stylix theming + - `waybarConfig.terminal` - Terminal for on-click commands (default: "ghostty") + - `waybarConfig.launcher` - App launcher command (default: "wofi --show=drun") + - `waybarConfig.fontSize` - Base font size (default: 16) + - `waybarConfig.font` - Font family (default: "Overpass Nerd Font") + - `waybarConfig.position` - Bar position: top/bottom (default: "top") + - `waybarConfig.margin` - Margin in pixels (default: 3) + - `waybarConfig.extraModulesLeft` - Additional left modules + - `waybarConfig.extraModulesRight` - Additional right modules + - `waybarConfig.windowRewriteRules` - Additional window title rewrite rules + - `waybarConfig.workspaceIcons` - Additional workspace icons + +### 6. Dotfiles Deleted + +| Dotfile | Status | +|---------|--------| +| `/home/nate/nixos/frame12/dotfiles/ghostty/` | DELETED | +| `/home/nate/nixos/shared/dotfiles/ghostty/` | DELETED | +| `/home/nate/nixos/shared/linked-dotfiles/helix/` | DELETED | +| `/home/nate/nixos/frame12/linked-dotfiles/waybar/` | DELETED | + +### 7. Symlinks Removed + +- Removed `helix` from `xdg.configFile` in home.nix +- Removed `waybar` from `xdg.configFile` in home.nix + +### 8. Packages Removed from Manual Lists + +**From `home.nix` home.packages:** +- helix (now programs.helix) +- ghostty (now programs.ghostty) +- bat (now programs.bat) +- fzf (now programs.fzf) +- mpv (now programs.mpv) + +**From `niri_home.nix` home.packages:** +- wofi (now programs.wofi) +- waybar (now programs.waybar via waybarConfig) + +**From `niri_conf.nix` environment.systemPackages:** +- foot (now programs.foot in home-manager) +- waybar (now programs.waybar via waybarConfig) +- wofi (now programs.wofi) + +--- + +## File Structure After Migration + +``` +frame12/modules/home-manager/ +├── home.nix # Main home config, imports programs.nix +└── programs.nix # All Stylix-themed program configs + +frame12/modules/niri/ +├── niri_home.nix # Niri home config, imports shared waybar.nix +└── niri_conf.nix # Niri system config + +shared/modules/home-manager/ +└── waybar.nix # Parameterized waybar module with Stylix theming +``` + +--- + +## Applications WITHOUT Direct Stylix Support + +These retain manual CSS/config with catppuccin colors: + +| Application | Config Location | Notes | +|-------------|-----------------|-------| +| SwayNC | `/home/nate/nixos/shared/dotfiles/swaync/` | Manual CSS with catppuccin colors | +| Niri | `/home/nate/nixos/frame12/linked-dotfiles/niri/` | Border colors are custom gradients | + +--- + +## Testing + +```bash +# Dry-run build (validates configuration) +nix build .#nixosConfigurations.frame12.config.system.build.toplevel --dry-run + +# Full rebuild +sudo nixos-rebuild switch --flake .#frame12 + +# Validate niri config +niri validate +``` + +--- + +## Reference: Stylix Base16 Color Variables + +Stylix provides these CSS variables for waybar and other GTK apps: +- `@base00` through `@base0F` - Base16 color palette +- Colors map to catppuccin-macchiato scheme + +## Reference: Stylix Documentation + +- Installation: https://nix-community.github.io/stylix/installation.html +- Configuration: https://nix-community.github.io/stylix/configuration.html +- Styling guide: https://nix-community.github.io/stylix/styling.html diff --git a/flake.lock b/flake.lock index 89a508c..9d337e7 100644 --- a/flake.lock +++ b/flake.lock @@ -1,20 +1,86 @@ { "nodes": { - "catppuccin": { + "base16": { "inputs": { - "nixpkgs": "nixpkgs" + "fromYaml": "fromYaml" }, "locked": { - "lastModified": 1770551880, - "narHash": "sha256-+cS5yXWsSLiK36+PP/+dcQdxpXSclx2d65p7l6Dis+A=", - "owner": "catppuccin", - "repo": "nix", - "rev": "db4dfe3f2a80e9c33492d839accd49f75c7324c2", + "lastModified": 1755819240, + "narHash": "sha256-qcMhnL7aGAuFuutH4rq9fvAhCpJWVHLcHVZLtPctPlo=", + "owner": "SenchoPens", + "repo": "base16.nix", + "rev": "75ed5e5e3fce37df22e49125181fa37899c3ccd6", "type": "github" }, "original": { - "owner": "catppuccin", - "repo": "nix", + "owner": "SenchoPens", + "repo": "base16.nix", + "type": "github" + } + }, + "base16-fish": { + "flake": false, + "locked": { + "lastModified": 1765809053, + "narHash": "sha256-XCUQLoLfBJ8saWms2HCIj4NEN+xNsWBlU1NrEPcQG4s=", + "owner": "tomyun", + "repo": "base16-fish", + "rev": "86cbea4dca62e08fb7fd83a70e96472f92574782", + "type": "github" + }, + "original": { + "owner": "tomyun", + "repo": "base16-fish", + "rev": "86cbea4dca62e08fb7fd83a70e96472f92574782", + "type": "github" + } + }, + "base16-helix": { + "flake": false, + "locked": { + "lastModified": 1760703920, + "narHash": "sha256-m82fGUYns4uHd+ZTdoLX2vlHikzwzdu2s2rYM2bNwzw=", + "owner": "tinted-theming", + "repo": "base16-helix", + "rev": "d646af9b7d14bff08824538164af99d0c521b185", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-helix", + "type": "github" + } + }, + "base16-vim": { + "flake": false, + "locked": { + "lastModified": 1732806396, + "narHash": "sha256-e0bpPySdJf0F68Ndanwm+KWHgQiZ0s7liLhvJSWDNsA=", + "owner": "tinted-theming", + "repo": "base16-vim", + "rev": "577fe8125d74ff456cf942c733a85d769afe58b7", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-vim", + "rev": "577fe8125d74ff456cf942c733a85d769afe58b7", + "type": "github" + } + }, + "firefox-gnome-theme": { + "flake": false, + "locked": { + "lastModified": 1764873433, + "narHash": "sha256-1XPewtGMi+9wN9Ispoluxunw/RwozuTRVuuQOmxzt+A=", + "owner": "rafaelmardojai", + "repo": "firefox-gnome-theme", + "rev": "f7ffd917ac0d253dbd6a3bf3da06888f57c69f92", + "type": "github" + }, + "original": { + "owner": "rafaelmardojai", + "repo": "firefox-gnome-theme", "type": "github" } }, @@ -39,6 +105,62 @@ "type": "github" } }, + "flake-parts_2": { + "inputs": { + "nixpkgs-lib": [ + "stylix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1767609335, + "narHash": "sha256-feveD98mQpptwrAEggBQKJTYbvwwglSbOv53uCfH9PY=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "250481aafeb741edfe23d29195671c19b36b6dca", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, + "fromYaml": { + "flake": false, + "locked": { + "lastModified": 1731966426, + "narHash": "sha256-lq95WydhbUTWig/JpqiB7oViTcHFP8Lv41IGtayokA8=", + "owner": "SenchoPens", + "repo": "fromYaml", + "rev": "106af9e2f715e2d828df706c386a685698f3223b", + "type": "github" + }, + "original": { + "owner": "SenchoPens", + "repo": "fromYaml", + "type": "github" + } + }, + "gnome-shell": { + "flake": false, + "locked": { + "host": "gitlab.gnome.org", + "lastModified": 1767737596, + "narHash": "sha256-eFujfIUQDgWnSJBablOuG+32hCai192yRdrNHTv0a+s=", + "owner": "GNOME", + "repo": "gnome-shell", + "rev": "ef02db02bf0ff342734d525b5767814770d85b49", + "type": "gitlab" + }, + "original": { + "host": "gitlab.gnome.org", + "owner": "GNOME", + "ref": "gnome-49", + "repo": "gnome-shell", + "type": "gitlab" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -78,16 +200,16 @@ }, "nixpkgs": { "locked": { - "lastModified": 1770197578, - "narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=", - "owner": "NixOS", + "lastModified": 1770464364, + "narHash": "sha256-z5NJPSBwsLf/OfD8WTmh79tlSU8XgIbwmk6qB1/TFzY=", + "owner": "nixos", "repo": "nixpkgs", - "rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2", + "rev": "23d72dabcb3b12469f57b37170fcbc1789bd7457", "type": "github" }, "original": { - "owner": "NixOS", - "ref": "nixos-unstable", + "owner": "nixos", + "ref": "nixos-25.11", "repo": "nixpkgs", "type": "github" } @@ -109,22 +231,6 @@ } }, "nixpkgs_2": { - "locked": { - "lastModified": 1770464364, - "narHash": "sha256-z5NJPSBwsLf/OfD8WTmh79tlSU8XgIbwmk6qB1/TFzY=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "23d72dabcb3b12469f57b37170fcbc1789bd7457", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-25.11", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_3": { "locked": { "lastModified": 1770562336, "narHash": "sha256-ub1gpAONMFsT/GU2hV6ZWJjur8rJ6kKxdm9IlCT0j84=", @@ -143,7 +249,7 @@ "nur": { "inputs": { "flake-parts": "flake-parts", - "nixpkgs": "nixpkgs_3" + "nixpkgs": "nixpkgs_2" }, "locked": { "lastModified": 1770671471, @@ -159,14 +265,170 @@ "type": "github" } }, + "nur_2": { + "inputs": { + "flake-parts": [ + "stylix", + "flake-parts" + ], + "nixpkgs": [ + "stylix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1767886815, + "narHash": "sha256-pB2BBv6X9cVGydEV/9Y8+uGCvuYJAlsprs1v1QHjccA=", + "owner": "nix-community", + "repo": "NUR", + "rev": "4ff84374d77ff62e2e13a46c33bfeb73590f9fef", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "NUR", + "type": "github" + } + }, "root": { "inputs": { - "catppuccin": "catppuccin", "home-manager": "home-manager", "nixos-hardware": "nixos-hardware", - "nixpkgs": "nixpkgs_2", + "nixpkgs": "nixpkgs", "nixpkgs-unstable": "nixpkgs-unstable", - "nur": "nur" + "nur": "nur", + "stylix": "stylix" + } + }, + "stylix": { + "inputs": { + "base16": "base16", + "base16-fish": "base16-fish", + "base16-helix": "base16-helix", + "base16-vim": "base16-vim", + "firefox-gnome-theme": "firefox-gnome-theme", + "flake-parts": "flake-parts_2", + "gnome-shell": "gnome-shell", + "nixpkgs": [ + "nixpkgs" + ], + "nur": "nur_2", + "systems": "systems", + "tinted-foot": "tinted-foot", + "tinted-kitty": "tinted-kitty", + "tinted-schemes": "tinted-schemes", + "tinted-tmux": "tinted-tmux", + "tinted-zed": "tinted-zed" + }, + "locked": { + "lastModified": 1770308890, + "narHash": "sha256-7bx8Bn9B2g/loBaz+uLwdKI2rUW+RhDPyP/MqAgvrxU=", + "owner": "nix-community", + "repo": "stylix", + "rev": "7e7fa955abac04a8e118b1cedf930a8fd41c34a6", + "type": "github" + }, + "original": { + "owner": "nix-community", + "ref": "release-25.11", + "repo": "stylix", + "type": "github" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "tinted-foot": { + "flake": false, + "locked": { + "lastModified": 1726913040, + "narHash": "sha256-+eDZPkw7efMNUf3/Pv0EmsidqdwNJ1TaOum6k7lngDQ=", + "owner": "tinted-theming", + "repo": "tinted-foot", + "rev": "fd1b924b6c45c3e4465e8a849e67ea82933fcbe4", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-foot", + "rev": "fd1b924b6c45c3e4465e8a849e67ea82933fcbe4", + "type": "github" + } + }, + "tinted-kitty": { + "flake": false, + "locked": { + "lastModified": 1735730497, + "narHash": "sha256-4KtB+FiUzIeK/4aHCKce3V9HwRvYaxX+F1edUrfgzb8=", + "owner": "tinted-theming", + "repo": "tinted-kitty", + "rev": "de6f888497f2c6b2279361bfc790f164bfd0f3fa", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-kitty", + "type": "github" + } + }, + "tinted-schemes": { + "flake": false, + "locked": { + "lastModified": 1767817087, + "narHash": "sha256-eGE8OYoK6HzhJt/7bOiNV2cx01IdIrHL7gXgjkHRdNo=", + "owner": "tinted-theming", + "repo": "schemes", + "rev": "bd99656235aab343e3d597bf196df9bc67429507", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "schemes", + "type": "github" + } + }, + "tinted-tmux": { + "flake": false, + "locked": { + "lastModified": 1767489635, + "narHash": "sha256-e6nnFnWXKBCJjCv4QG4bbcouJ6y3yeT70V9MofL32lU=", + "owner": "tinted-theming", + "repo": "tinted-tmux", + "rev": "3c32729ccae99be44fe8a125d20be06f8d7d8184", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "tinted-tmux", + "type": "github" + } + }, + "tinted-zed": { + "flake": false, + "locked": { + "lastModified": 1767488740, + "narHash": "sha256-wVOj0qyil8m+ouSsVZcNjl5ZR+1GdOOAooAatQXHbuU=", + "owner": "tinted-theming", + "repo": "base16-zed", + "rev": "11abb0b282ad3786a2aae088d3a01c60916f2e40", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-zed", + "type": "github" } } }, diff --git a/flake.nix b/flake.nix index 52932fe..5de3f38 100644 --- a/flake.nix +++ b/flake.nix @@ -9,12 +9,15 @@ inputs.nixpkgs.follows = "nixpkgs"; }; # bonus inputs - catppuccin.url = "github:catppuccin/nix"; + stylix = { + url = "github:nix-community/stylix/release-25.11"; + inputs.nixpkgs.follows = "nixpkgs"; + }; nur.url = "github:nix-community/NUR"; nixos-hardware.url = "github:NixOS/nixos-hardware/master"; }; - outputs = { self, nixpkgs, nixpkgs-unstable, catppuccin, nur, home-manager, nixos-hardware, ... } @ inputs: + outputs = { self, nixpkgs, nixpkgs-unstable, stylix, nur, home-manager, nixos-hardware, ... } @ inputs: let inherit (self) outputs; system = "x86_64-linux"; @@ -48,7 +51,6 @@ inherit inputs outputs timeZone system; }; modules = [ - catppuccin.nixosModules.catppuccin # Setup home manager inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; @@ -67,17 +69,11 @@ inherit inputs outputs timeZone system; }; modules = [ - catppuccin.nixosModules.catppuccin # Setup home manager inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; - home-manager.users.nate = { - imports = [ - ./nate-work/modules/home-manager/home.nix - catppuccin.homeModules.catppuccin - ]; - }; + home-manager.users.nate = import ./nate-work/modules/home-manager/home.nix; home-manager.extraSpecialArgs = { inherit inputs outputs unstablePkgs; }; @@ -127,17 +123,12 @@ inherit inputs outputs timeZone system; }; modules = [ - catppuccin.nixosModules.catppuccin + stylix.nixosModules.stylix # Setup home manager inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; - home-manager.users.nate = { - imports = [ - ./frame12/modules/home-manager/home.nix - catppuccin.homeModules.catppuccin - ]; - }; + home-manager.users.nate = import ./frame12/modules/home-manager/home.nix; home-manager.extraSpecialArgs = { inherit inputs outputs unstablePkgs; }; diff --git a/frame12/default.nix b/frame12/default.nix index d1d0603..fc59f8f 100644 --- a/frame12/default.nix +++ b/frame12/default.nix @@ -19,6 +19,52 @@ de = desktop; }; + # Stylix theming + stylix = { + enable = true; + image = ./wallpaper.png; + + # Check with `nix build nixpkgs#base16-schemes && ls result/share/themes` + base16Scheme = "${pkgs.base16-schemes}/share/themes/woodland.yaml"; + polarity = "dark"; + + # System-wide cursor + cursor = { + package = pkgs.bibata-cursors; + name = "Bibata-Modern-Classic"; + size = 32; + }; + + # Fonts + fonts = { + serif = { + package = pkgs.lato; + name = "Lato"; + }; + sansSerif = { + package = pkgs.lato; + name = "Lato"; + }; + monospace = { + package = pkgs.maple-mono.NF; + name = "Maple Mono NF"; + }; + emoji = { + package = pkgs.noto-fonts-color-emoji; + name = "Noto Color Emoji"; + }; + sizes = { + applications = 12; + desktop = 10; + popups = 10; + terminal = 11; + }; + }; + + # Keep custom Framework plymouth theme + targets.plymouth.enable = false; + }; + # Limit the number of generations to keep boot.loader.systemd-boot.configurationLimit = 5; diff --git a/frame12/dotfiles/ghostty/config b/frame12/dotfiles/ghostty/config deleted file mode 100644 index 4f54371..0000000 --- a/frame12/dotfiles/ghostty/config +++ /dev/null @@ -1,41 +0,0 @@ -font-size = 11 -font-family = "Monaspace Xenon Var" -font-family-bold = "Monaspace Argon Var" -font-family-italic = "Monaspace Radon Var" -font-family-bold-italic = "Monaspace Krypton Var" - -font-variation = wght=400 -font-variation = wdth=100 -font-variation = slnt=-2 - -font-variation-bold = wght=600 -font-variation-bold = wdth=100 - -font-variation-italic = wght=400 -font-variation-italic = wdth=100 -font-variation-italic = slnt=-10 - -font-variation-bold-italic = wght=700 -font-variation-bold-italic = wdth=100 -font-variation-bold-italic = slnt=-3 - -# Liguratures -font-feature = +ss01, +ss02, +ss03, +ss04, +ss05, +ss06, +ss07, +ss08, +ss09, +ss10 -# Enables texture healing -font-feature = +calt -font-feature = +liga - -### -# Keybinds -### - -keybind = ctrl+shift+plus=increase_font_size:1 -# keybind = ctrl+minus=decrease_font_size:1 - -### -# Misc -### - -window-padding-x = 4 -window-padding-y = 4 -keybind = shift+enter=text:\n diff --git a/frame12/linked-dotfiles/waybar/config b/frame12/linked-dotfiles/waybar/config deleted file mode 100644 index 2f04934..0000000 --- a/frame12/linked-dotfiles/waybar/config +++ /dev/null @@ -1,315 +0,0 @@ -// Global -{ - "layer": "top", - "position": "top", - "margin-top": 3, - "margin-left": 3, - "margin-right": 3, - "margin-bottom": 3, - - // If height property would be not present, it'd be calculated dynamically - // "height": 60, - - "modules-left": [ - "custom/launcher", - "niri/workspaces", - "niri/window", - ], - - "modules-right": [ - "clock", - // "network", // using network applet in tray - // "idle_inhibitor", - "custom/storage", - "memory", - "cpu", - // "pulseaudio", - // "custom/keyboard-layout", - "battery", - // "backlight", - "custom/wlsunset", - "tray", - //"custom/weather", - "custom/power", - ], - - // Modules - - "idle_inhibitor": { - "format": "{icon} ", - "format-icons":{ - "activated": "", - "deactivated": "" - } - }, - - "battery": { - "states": { - // "good": 95, - "warning": 30, - "critical": 15 - }, - "format": "{icon} {capacity}%", - "format-charging": "{capacity}% 󰂄", - "format-plugged": "{capacity}% ", - // "format-good": "", // An empty format will hide the module - // "format-full": "", - "format-icons": ["", "", "", "", ""] - }, - - "clock": { - "interval": 1, - // "format-alt": " {:%e %b %Y}", // Icon: calendar-alt - "format": "{:%I:%M.%S %p}", - "tooltip-format": "{:%e %B %Y}" - }, - - "cpu": { - "interval": 5, - "format": " {usage}%", // Icon: microchip - "states": { - "warning": 70, - "critical": 90, - }, - "on-click": "ghostty -e 'htop'", - }, - - "memory": { - "interval": 5, - "format": " {}%", // Icon: memory - "on-click": "ghostty -e 'htop'", - "states": { - "warning": 70, - "critical": 90 - } - }, - - "network": { - "interval": 5, - "format-wifi": "", // Icon: wifi - "format-ethernet": " {ifname}: {ipaddr}/{cidr}", // Icon: ethernet - "format-disconnected": "⚠ Disconnected", - "tooltip-format": "{essid} - {ifname}:{ipaddr} {bandwidthUpBytes} {bandwidthDownBytes}", - "on-click": "ghostty -e 'nmtui'", - }, - "network#vpn": { - "interface": "tun0", - "format": " {signalStrength}%", - "format-disconnected": "⚠ Disconnected", - "tooltip-format": "{essid} - {ifname}:{ipaddr} {bandwidthUpBytes} {bandwidthDownBytes}", - }, - - "niri/window": { - "format": "{title}", - "icon": true, - "icon-size": 20, - "rewrite": { - // Firefox - "(.*) — Mozilla Firefox": " $1", - "(.*) - Mozilla Firefox": " $1", - "Mozilla Firefox": " Firefox", - - // Chrome/Chromium - "(.*) - Google Chrome": " $1", - "(.*) - Chromium": " $1", - "Google Chrome": " Chrome", - "Chromium": " Chromium", - - // Terminal applications - "(.*) - zsh": " $1", - "(.*) - bash": " $1", - "(.*) - fish": " $1", - "ghostty": " Terminal", - "kitty": " Terminal", - "alacritty": " Terminal", - "ghostty": " Terminal", - - // Text editors and IDEs - "(.*) - Visual Studio Code": " $1", - "(.*) - Code": " $1", - "(.*) - Vim": " $1", - "(.*) - Neovim": " $1", - "(.*) - Emacs": " $1", - "Visual Studio Code": " VS Code", - - // File managers - "(.*)Nautilus": " Files: $1", - "Files": " Files", - "Thunar": " Files", - "Dolphin": " Files", - - // Communication apps - "Slack (.*)": " $1", - "Slack": " Slack", - "Signal": " Signal", - "Discord": " Discord", - "Telegram": " Telegram", - - // Media and entertainment - "Spotify": " Spotify", - "Steam": " Steam", - "(.*) - YouTube": "󰗃 $1", - "VLC media player": "󰕼 VLC", - - // Development tools - "(.*) - GitHub": " $1", - "GitKraken": " GitKraken", - "Postman": " Postman", - - // System applications - "System Monitor": " System Monitor", - "Task Manager": " Task Manager", - "Settings": " Settings", - "Control Panel": " Settings", - - // Office applications - "(.*) - LibreOffice Writer": " $1", - "(.*) - LibreOffice Calc": " $1", - "(.*) - LibreOffice Impress": " $1", - - // Remove common suffixes that don't add value - "^(.*) - .*$": "$1", - "^(.*) | .*$": "$1", - - // Fallback for empty/unnamed windows - "^$": "Desktop" - } - }, - - "niri/workspaces": { - "disable-click": false, - "disable-markup": false, - "all-outputs": true, - "format": " {icon} ", - "format-icons": { - "term": "", - "net": "", - "chat": "󰭻", - "scratch": "", - // Numeric Fallback - "1": " 1", - "2": " 2", - "3": " 3", - "4": " 4", - "5": " 5", - "6": " 6", - "7": " 7", - "8": " 8", - "9": " 9", - } - }, - - "pulseaudio": { - "scroll-step": 1, // %, can be a float - "format": "{icon} {volume}%", - "format-bluetooth": "{volume}% {icon}  {format_source}", - "format-bluetooth-muted": " {icon}  {format_source}", - "format-muted": " {format_source}", - "format-source": "{volume}% ", - "format-source-muted": "", - "format-icons": { - "headphone": ["", "", "", "", ""], - "hands-free": "", - "headset": "", - "phone": "", - "portable": "", - "car": "", - "default": ["", "", ""] - }, - "on-click": "pavucontrol", - "on-scroll-up": "pactl set-sink-volume @DEFAULT_SINK@ +2%", - "on-scroll-down": "pactl set-sink-volume @DEFAULT_SINK@ -2%", - }, - - // "custom/temp": { - // "exec": "notify-send \"temp thing\"", - // "interval": "once", - // "signal": 8, - // }, - - "tray": { - "icon-size": 20, - "spacing":10, - }, - - "backlight": { - "format": "{icon} {percent}%", - "format-icons": ["󰹐", "󱩏", "󱩑", "󱩓", "󱩕", "󰛨"], - "on-scroll-down": "brightnessctl -c backlight set 1%-", - "on-scroll-up": "brightnessctl -c backlight set +1%", - "min-brightness": 1 - }, - - "custom/storage": { - "format": "{icon} {percentage}%", - "format-icons": { - "default": "", - "warning": "", - "critical": "", - }, - "exec": "usage=$(df / --output=pcent | tail -n1 | tr -d ' %'); if [ $usage -ge 90 ]; then class=\"critical\"; elif [ $usage -ge 75 ]; then class=\"warning\"; else class=\"default\"; fi; echo \"{\\\"percentage\\\":$usage,\\\"class\\\":\\\"$class\\\"}\"", - "return-type": "json", - "interval": 30, - "tooltip-format": "Root filesystem: {percentage}% used", - }, - - "custom/signal": { - "format": "  ", - "on-click": "exec signal", - "tooltip": false, - }, - - "custom/steam": { - "format": "  ", - "on-click": "exec steam", - "tooltip": false, - }, - - "custom/spotify": { - "format": "  ", - "on-click": "exec flatpak run com.spotify.Client", - "tooltip": false, - }, - - "custom/firefox": { - "format": "  ", - "on-click": "exec firefox", - "tooltip": false, - }, - - - "custom/slack": { - "format": "  ", - "on-click": "slack", - "tooltip": false, - "exec if": "pgrep slack" - }, - - - "custom/files": { - "format": " 󰉋 ", - "on-click": "exec nautilus", - "tooltip": false, - }, - - "custom/launcher": { - "format":" ", - "on-click": "exec wofi -c ~/.config/wofi/config --show=drun", - "tooltip": false, - }, - - "custom/wlsunset": { - "format": "{}", - "exec": "~/.config/waybar/scripts/wlsunset-status.sh", - "on-click": "~/.config/waybar/scripts/wlsunset-toggle.sh", - "interval": "once", - "signal": 8, - "tooltip": false, - }, - - "custom/power": { - "format":"⏻", - "on-click": "exec ~/.config/waybar/scripts/power-menu.sh", - "tooltip": false, - }, -} diff --git a/frame12/linked-dotfiles/waybar/scripts/keyboard_layout.sh b/frame12/linked-dotfiles/waybar/scripts/keyboard_layout.sh deleted file mode 100755 index 04cf5e1..0000000 --- a/frame12/linked-dotfiles/waybar/scripts/keyboard_layout.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/usr/bin/env bash - -entries="Default Colemak" - -selected=$(printf '%s\n' $entries | wofi --conf=$HOME/.config/wofi/config.power --style=$HOME/.config/wofi/style.widgets.css | awk '{print tolower($1)}') - -case $selected in - default) - swaymsg input type:keyboard xkb_layout "us" - swaymsg input type:keyboard xkb_variant '""' - ;; - colemak) - swaymsg input type:keyboard xkb_layout "us" - swaymsg input type:keyboard xkb_variant "colemak_dh" - ;; -esac diff --git a/frame12/linked-dotfiles/waybar/scripts/power-menu.sh b/frame12/linked-dotfiles/waybar/scripts/power-menu.sh deleted file mode 100755 index e226e4d..0000000 --- a/frame12/linked-dotfiles/waybar/scripts/power-menu.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/usr/bin/env bash - -entries="Logout Suspend Reboot Shutdown" - -selected=$(printf '%s\n' $entries | wofi --show=dmenu --conf=$HOME/.config/wofi/config.power --style=$HOME/.config/wofi/style.widgets.css | awk '{print tolower($1)}') - -case $selected in - logout) - swaymsg exit;; - suspend) - exec systemctl suspend;; - reboot) - exec systemctl reboot;; - shutdown) - exec systemctl poweroff -i;; -esac diff --git a/frame12/linked-dotfiles/waybar/scripts/wlsunset-status.sh b/frame12/linked-dotfiles/waybar/scripts/wlsunset-status.sh deleted file mode 100755 index 2096a55..0000000 --- a/frame12/linked-dotfiles/waybar/scripts/wlsunset-status.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env bash - -# Check if wlsunset service is active and return appropriate icon -if systemctl --user is-active --quiet wlsunset; then - echo "󰖜" # Moon/sunset icon (night mode active) -else - echo "󰖚" # Sun icon (day mode) -fi \ No newline at end of file diff --git a/frame12/linked-dotfiles/waybar/scripts/wlsunset-toggle.sh b/frame12/linked-dotfiles/waybar/scripts/wlsunset-toggle.sh deleted file mode 100755 index 9557a66..0000000 --- a/frame12/linked-dotfiles/waybar/scripts/wlsunset-toggle.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env bash - -# Check if wlsunset service is active -if systemctl --user is-active --quiet wlsunset; then - # Service is running, stop it - systemctl --user stop wlsunset -else - # Service is not running, start it - systemctl --user start wlsunset -fi - -# Send signal to waybar to update the display -pkill -SIGRTMIN+8 waybar \ No newline at end of file diff --git a/frame12/linked-dotfiles/waybar/style.css b/frame12/linked-dotfiles/waybar/style.css deleted file mode 100644 index dab127c..0000000 --- a/frame12/linked-dotfiles/waybar/style.css +++ /dev/null @@ -1,342 +0,0 @@ -/* ============================================================================= - * - * Waybar configuration - * - * Configuration reference: https://github.com/Alexays/Waybar/wiki/Configuration - * - * =========================================================================== */ - -@define-color rosewater #f4dbd6; -@define-color flamingo #f0c6c6; -@define-color pink #f5bde6; -@define-color mauve #c6a0f6; -@define-color red #ed8796; -@define-color maroon #ee99a0; -@define-color peach #f5a97f; -@define-color yellow #eed49f; -@define-color green #a6da95; -@define-color teal #8bd5ca; -@define-color sky #91d7e3; -@define-color sapphire #7dc4e4; -@define-color blue #8aadf4; -@define-color lavender #b7bdf8; -@define-color text #cad3f5; -@define-color subtext1 #b8c0e0; -@define-color subtext0 #a5adcb; -@define-color overlay2 #939ab7; -@define-color overlay1 #8087a2; -@define-color overlay0 #6e738d; -@define-color surface2 #5b6078; -@define-color surface1 #494d64; -@define-color surface0 #363a4f; -@define-color base #24273a; -@define-color mantle #1e2030; -@define-color crust #181926; - - -/* ----------------------------------------------------------------------------- - * Keyframes - * -------------------------------------------------------------------------- */ -@keyframes blink-warning { - 70% { - color: @overlay0; - } - - to { - color: @overlay0; - background-color: @crust; - } -} - -@keyframes blink-critical { - 70% { - color: @overlay2; - } - - to { - color: @overlay2; - background-color: @base; - } -} - - -/* ----------------------------------------------------------------------------- - * Base styles - * -------------------------------------------------------------------------- */ -/* Reset all styles */ -* { - border: none; - border-radius: 0; - min-height: 30px; - margin: 0px; - padding: 0px; -} - -/* The whole bar */ -#waybar { - background: transparent; - background-color: transparent; - font-family: Overpass Nerd Font; - font-size: 16px; - color: @text; -} - -#taskbar { - background: transparent; -} - -#taskbar button { - padding-left: 3px; - padding-right: 3px; - margin-left: 3px; - margin-right: 3px; - /* color: transparent; */ - border-bottom: 2px solid; -} - -#taskbar button.active { - color: @green; -} - -.modules-left, -.modules-right { - /* margin: 8px 8px 1px 8px; */ - background: transparent; - /* color: @; */ - background-color: @base; - border-radius: 20px; - padding: 0px 6px 0px 6px; - border-style: solid; - border-width: 3px; - border-color: @surface0; -} - -/* Hide empty center module */ -.modules-center { - background: transparent; - border: none; - padding: 0; - min-height: 0; -} - -/* Every modules */ -#backlight, -#battery, -#clock, -#cpu, -#custom-storage, -#custom-keyboard-layout, -#custom-PBPbattery, -#custom-weather, -#idle_inhibitor, -#memory, -#mode, -#network, -#pulseaudio, -#temperature, -#tray { - padding: 0.5rem 0.6rem; - margin: 1px 0px; -} - -#clock { - margin-left: 5px; - margin-right: 5px; - min-width: 140px; -} - -#backlight, -#battery, -#cpu, -#custom-storage, -#memory, -#network, -#pulseaudio, -#temperature { - min-width: 90px; -} - - -/* ----------------------------------------------------------------------------- - * Modules styles - * -------------------------------------------------------------------------- */ - -#battery { - animation-timing-function: linear; - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#battery.warning, -#custom-storage.warning { - color: @flamingo; -} - -#battery.critical, -#custom-storage.critical { - color: @red; -} - -#battery.warning.discharging { - animation-name: blink-warning; - animation-duration: 3s; -} - -#battery.critical.discharging { - animation-name: blink-critical; - animation-duration: 2s; -} - -#cpu.warning { - color: @flamingo; -} - -#cpu.critical { - color: @red; -} - -#memory { - animation-timing-function: linear; - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#memory.warning { - color: @flamingo; -} - -#memory.critical { - color: @red; - animation-name: blink-critical; - animation-duration: 2s; - padding-left: 5px; - padding-right: 5px; -} - -#mode { - background: @overlay0; - border-bottom: 3px transparent; - color: @text; - margin-left: 5px; - margin-right: 5px; - border-radius: 20px; -} - -#network.disconnected { - color: @flamingo; -} - -#pulseaudio { - padding-top: 6px; -} - -#pulseaudio.muted { - color: @sky; -} - -#temperature.critical { - color: @red; -} - -#window { - font-weight: bold; - margin-left: 20px; - margin-right: 10px; -} - -#workspaces { - font-size: 16px; -} - -#workspaces button { - /* border-bottom: 3px solid transparent; */ - margin-bottom: 0px; - padding: 0px; -} - -#custom-launcher { - color: @lavenderblush; -} - -/* @define-color rosewater #f4dbd6; */ -/* @define-color flamingo #f0c6c6; */ -/* @define-color pink #f5bde6; */ -/* @define-color mauve #c6a0f6; */ -/* @define-color red #ed8796; */ -/* @define-color maroon #ee99a0; */ -/* @define-color peach #f5a97f; */ -/* @define-color yellow #eed49f; */ -/* @define-color green #a6da95; */ -/* @define-color teal #8bd5ca; */ -/* @define-color sky #91d7e3; */ -/* @define-color sapphire #7dc4e4; */ -/* @define-color blue #8aadf4; */ -/* @define-color lavender #b7bdf8; */ - - -#custom-signal { - color: @lavender; - padding: 0px 5px 0px 5px; -} - -#custom-steam { - color: @teal; - padding: 0px 5px 0px 5px; -} - -#custom-spotify { - color: @green; - padding: 0px 5px 0px 5px; -} - -#custom-firefox { - color: @yellow; - padding: 0px 5px 0px 5px; -} - -#custom-slack { - color: @peach; - padding: 0px 5px 0px 5px; -} - -#custom-files { - color: @pink; - padding: 0px 5px 0px 5px; -} - -#custom-pomo { - color: @red; - padding: 0px 5px 0px 5px; -} - -#wiggle { - animation-name: blink-warning; -} - -#workspaces button.active { - border-bottom: 3px solid @lavender; - color: @green; -} - -#workspaces button.urgent { - border-color: @lavender; - color: @yellow; -} - -#custom-power { - margin-left: 15px; - margin-right: 15px; - /* font-size: 16px; */ - color: @flamingo; -} - -#custom-launcher { - /* font-size: 24px; */ - margin-left: 15px; - margin-right: 10px; -} - -#backlight.icon { - padding-right: 1px; - /* font-size: 16px; */ -} \ No newline at end of file diff --git a/frame12/modules/home-manager/home.nix b/frame12/modules/home-manager/home.nix index 4470f58..436d3a4 100644 --- a/frame12/modules/home-manager/home.nix +++ b/frame12/modules/home-manager/home.nix @@ -10,6 +10,7 @@ ../../../shared/modules/apps/firefox/firefox.nix ../../../shared/modules/home-manager/git-autosync.nix ../niri/niri_home.nix + ./programs.nix ]; home.username = userName; @@ -20,6 +21,9 @@ firefoxApp.enable = true; fonts.fontconfig.enable = true; + # Stylix auto-theming - applies to all programs..enable apps + stylix.autoEnable = true; + # Enable niri home configuration nirihome = { enable = true; @@ -27,12 +31,11 @@ }; # Additional user packages + # Note: Programs with Stylix theming are in programs.nix home.packages = with pkgs; [ # # Dev Tools # - helix - ghostty jq python3 unstable.claude-code @@ -150,16 +153,14 @@ # # Unix tools # - bat duf dust fd - fzf lsd ripgrep tre-command gtop - htop + htop # kept alongside btop in programs.nix neofetch unzip nmap @@ -170,7 +171,6 @@ # Photo / Video # imv - mpv ffmpeg yt-dlp @@ -183,15 +183,11 @@ # # Style # - catppuccin-kvantum libsForQt5.qtstyleplugin-kvantum libsForQt5.qt5ct - # Install fonts - lato + # Additional fonts (main fonts managed by Stylix) unstable.nerd-fonts.hurmit unstable.nerd-fonts.overpass - unstable.nerd-fonts.monaspace - monaspace recursive ]; @@ -221,29 +217,12 @@ value = { source = localDotfilesPath + "/${name}"; }; }) (builtins.attrNames (builtins.readDir localDotfilesPath))) else {}) - { - ".icons/default/index.theme".text = '' - [icon theme] - Inherits=Catppuccin-Macchiato-Lavender-Cursors - ''; - } ]; # Active symlinks xdg.configFile = { # Active linked dotfiles - "niri".source = config.lib.file.mkOutOfStoreSymlink "/home/nate/nixos/frame12/linked-dotfiles/niri"; - "waybar".source = config.lib.file.mkOutOfStoreSymlink "/home/nate/nixos/frame12/linked-dotfiles/waybar"; - # Shared - "helix".source = config.lib.file.mkOutOfStoreSymlink "/home/nate/nixos/shared/linked-dotfiles/helix"; - - # Theme configuration - "gtk-4.0/assets".source = "${config.gtk.theme.package}/share/themes/${config.gtk.theme.name}/gtk-4.0/assets"; - "gtk-4.0/gtk.css".source = "${config.gtk.theme.package}/share/themes/${config.gtk.theme.name}/gtk-4.0/gtk.css"; - "gtk-4.0/gtk-dark.css".source = "${config.gtk.theme.package}/share/themes/${config.gtk.theme.name}/gtk-4.0/gtk-dark.css"; - "Kvantum/kvantum.kvconfig".source = (pkgs.formats.ini {}).generate "kvantum.kvconfig" { - General.theme = "catppuccin-macchiato-lavender"; - }; + "niri".source = config.lib.file.mkOutOfStoreSymlink "/home/nate/nixos/frame12/linked-dotfiles/niri"; }; # Override Flatpak Steam to disable GPU acceleration (fixes black window on Niri) @@ -257,7 +236,6 @@ }; home.sessionVariables = { - BAT_THEME="Catppuccin Macchiato"; EDITOR = "hx"; # For electron apps NIXOS_OZONE_WL = "1"; @@ -269,12 +247,10 @@ settings = { user.name = fullName; user.email = email; - include = { path = "${config.xdg.configHome}/macchiato.gitconfig"; }; init = { defaultBranch = "main"; }; pull = { ff = "only"; }; merge = { conflictStyle="zdiff3"; }; push = { autoSetupRemote="true"; }; - delta = { features = "Catppuccin Macchiato"; }; }; }; @@ -338,32 +314,7 @@ }; }; - qt = { - enable = true; - platformTheme.name = "qtct"; - style.name = "kvantum"; - }; - - gtk = { - enable = true; - cursorTheme = { - package = pkgs.catppuccin-cursors.macchiatoLavender; - name = "Catppuccin-Macchiato-Lavender-Cursors"; - }; - iconTheme = { - package = pkgs.catppuccin-papirus-folders; - name = "Papirus-Dark"; - }; - theme = { - name = "catppuccin-macchiato-lavender-compact+rimless"; - package = pkgs.catppuccin-gtk.override { - accents = [ "lavender" ]; - size = "compact"; - tweaks = [ "rimless" ]; - variant = "macchiato"; - }; - }; - }; + # Stylix handles Qt and GTK theming services.wlsunset = { enable = true; @@ -386,6 +337,16 @@ topMargin = 0.9; }; + # SwayNC - notification center (Stylix auto-themes this) + services.swaync = { + enable = true; + settings = { + positionX = "center"; + positionY = "top"; + notification-window-width = 800; + }; + }; + # Git autosync for star-command services.git-autosync = { enable = true; diff --git a/frame12/modules/home-manager/programs.nix b/frame12/modules/home-manager/programs.nix new file mode 100644 index 0000000..dba5239 --- /dev/null +++ b/frame12/modules/home-manager/programs.nix @@ -0,0 +1,418 @@ +# Stylix-themed program configurations +# All programs here are managed via programs..enable for Stylix auto-theming +{ config, pkgs, lib, ... }: + +{ + programs = { + # + # Terminals + # + ghostty = { + enable = true; + settings = { + # Font managed by Stylix, but we can override family here + # Stylix sets font-size via stylix.fonts.sizes.terminal + font-family = "Maple Mono NF"; + + # Ligatures - Maple Mono NF has full ligature support + font-feature = [ + "+calt" # contextual alternates + "+liga" # standard ligatures + ]; + + window-padding-x = 4; + window-padding-y = 4; + + keybind = [ + "ctrl+shift+plus=increase_font_size:1" + "shift+enter=text:\\n" + ]; + }; + }; + + foot = { + enable = true; + # Stylix handles colors and fonts + settings = { + main = { + pad = "4x4"; + }; + }; + }; + + # + # Editor + # + helix = { + enable = true; + # Stylix sets the theme, but we override syntax tokens for minimal highlighting + # Philosophy: Only keywords, strings, comments, numbers get color - rest is plain text + themes.stylix = { + # Inherit Stylix's base theme (UI, palette, etc.) + inherits = "stylix"; + + # Minimal syntax highlighting - only 4 categories get color + # Comments - stand out + "comment" = { fg = "yellow"; modifiers = ["italic"]; }; + + # Keywords - highlighted and italic + "keyword" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.control" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.directive" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.function" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.operator" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.return" = { fg = "magenta"; modifiers = ["italic"]; }; + "keyword.storage" = { fg = "magenta"; modifiers = ["italic"]; }; + + # Strings - highlighted + "string" = "green"; + "string.regexp" = "red"; + "string.special" = "green"; + + # Numbers/constants - highlighted + "constant.numeric" = "red"; + "constant.builtin" = "red"; + "constant.character.escape" = "red"; + + # Functions remain plain text + "function" = "text"; + "function.builtin" = "text"; + "function.method" = "text"; + "function.macro" = "text"; + + # Variables remain plain text + "variable" = "text"; + "variable.builtin" = "text"; + "variable.parameter" = "text"; + "variable.other.member" = "text"; + + # Types get subtle highlight + "type" = { fg = "cyan"; modifiers = ["italic"]; }; + "type.builtin" = "cyan"; + + # Top-level definitions get accent + "function.definition" = { fg = "text"; modifiers = ["bold"]; }; + "type.definition" = { fg = "text"; modifiers = ["bold"]; }; + + # Everything else plain + "constructor" = "text"; + "attribute" = "text"; + "label" = "text"; + "namespace" = "text"; + "tag" = "text"; + + # Punctuation slightly dimmed + "punctuation" = { fg = "text"; modifiers = ["dim"]; }; + "punctuation.bracket" = { fg = "text"; modifiers = ["dim"]; }; + "punctuation.delimiter" = { fg = "text"; modifiers = ["dim"]; }; + "punctuation.special" = { fg = "text"; modifiers = ["dim"]; }; + "operator" = { fg = "text"; modifiers = ["dim"]; }; + + # Markup + "markup.heading" = { fg = "cyan"; modifiers = ["bold"]; }; + "markup.list" = "magenta"; + "markup.bold" = { modifiers = ["bold"]; }; + "markup.italic" = { modifiers = ["italic"]; }; + "markup.strikethrough" = { modifiers = ["crossed_out"]; }; + "markup.link.url" = { fg = "blue"; modifiers = ["underlined"]; }; + "markup.link.text" = "magenta"; + "markup.quote" = "green"; + "markup.raw" = "green"; + }; + + settings = { + + keys.normal = { + # Navigation (Colemak-DH) + n = "move_char_left"; + i = "move_visual_line_down"; + e = "move_visual_line_up"; + o = "move_char_right"; + "S-tab" = "jump_backward"; + I = [ "page_cursor_half_down" "align_view_center" ]; + E = [ "page_cursor_half_up" "align_view_center" ]; + + # Modes + h = "insert_mode"; + H = "insert_at_line_start"; + l = "open_below"; + L = "open_above"; + + # Search + k = "search_next"; + K = "search_prev"; + + # Selection + C-s = "split_selection_on_newline"; + C-minus = "merge_selections"; + C-_ = "merge_consecutive_selections"; + "C-;" = "flip_selections"; + "C-:" = "ensure_selections_forward"; + "C-," = "remove_primary_selection"; + C-c = "change_selection_noyank"; + C-d = "delete_selection_noyank"; + "C-(" = "rotate_selection_contents_backward"; + "C-)" = "rotate_selection_contents_forward"; + C-x = "shrink_to_line_bounds"; + C-J = "join_selections_space"; + C-K = "remove_selections"; + C-o = "expand_selection"; + C-i = "shrink_selection"; + C-p = "select_prev_sibling"; + C-n = "select_next_sibling"; + + # Misc + "C-/" = "toggle_comments"; + "@" = ":append-output git config get user.email"; + + space = { + B = ":sh git log -n 5 --format='format:%%h (%%an: %%ar) %%s' --no-patch -L%{cursor_line},+1:%{buffer_name}"; + x = ":write-buffer-close"; + X = ":write-quit-all"; + o = ":config-open"; + h = "hover"; + k = "select_references_to_symbol_under_cursor"; + }; + + g = { + "/" = "goto_next_buffer"; + h = "goto_previous_buffer"; + n = [ "collapse_selection" "extend_to_line_start" ]; + o = [ "collapse_selection" "extend_to_line_end" ]; + e = "move_line_up"; + i = "move_line_down"; + l = "goto_last_line"; + p = "no_op"; + k = "no_op"; + j = "no_op"; + }; + + m.m = [ "select_mode" "match_brackets" "normal_mode" ]; + + "C-w" = { + h = "hsplit"; + C-h = "hsplit"; + n = "jump_view_left"; + C-n = "jump_view_left"; + i = "jump_view_down"; + I = "swap_view_down"; + C-i = "jump_view_down"; + e = "jump_view_up"; + E = "swap_view_up"; + C-e = "jump_view_up"; + o = "jump_view_right"; + O = "swap_view_right"; + C-o = "jump_view_right"; + # Remove old + s = "no_op"; + C-s = "no_op"; + H = "no_op"; + j = "no_op"; + J = "no_op"; + C-j = "no_op"; + k = "no_op"; + K = "no_op"; + C-k = "no_op"; + l = "no_op"; + L = "no_op"; + C-l = "no_op"; + }; + }; + + keys.select = { + n = "extend_char_left"; + i = "extend_line_down"; + e = "extend_line_up"; + o = "extend_char_right"; + I = [ "page_cursor_half_down" "align_view_center" ]; + E = [ "page_cursor_half_up" "align_view_center" ]; + + g = { + "/" = "goto_next_buffer"; + h = "goto_previous_buffer"; + n = "goto_line_start"; + o = "goto_line_end"; + e = "move_line_up"; + i = "move_line_down"; + l = "goto_last_line"; + p = "no_op"; + k = "no_op"; + j = "no_op"; + }; + }; + + editor = { + auto-format = true; + auto-save = true; + bufferline = "always"; + color-modes = true; + completion-timeout = 5; + cursorcolumn = true; + cursorline = true; + indent-heuristic = "tree-sitter"; + line-number = "relative"; + rulers = [ 120 ]; + text-width = 120; + end-of-line-diagnostics = "hint"; + + cursor-shape = { + insert = "bar"; + normal = "block"; + select = "underline"; + }; + + file-picker.hidden = false; + + indent-guides.render = true; + + inline-diagnostics = { + cursor-line = "warning"; + other-lines = "disable"; + prefix-len = 5; + max-diagnostics = 1; + max-wrap = 30; + }; + + lsp = { + display-messages = true; + display-inlay-hints = true; + }; + + soft-wrap = { + enable = true; + max-wrap = 30; + }; + + statusline = { + left = [ "mode" "file-modification-indicator" "spinner" "version-control" ]; + center = [ "file-name" ]; + right = [ "diagnostics" "selections" "register" "position" "file-encoding" ]; + mode.normal = "Normal"; + mode.insert = "Insert"; + mode.select = "Select"; + }; + + whitespace.render = { + space = "all"; + tab = "all"; + tabpad = "all"; + newline = "none"; + nbsp = "none"; + }; + + whitespace.characters = { + space = " "; + tab = "⇀"; + tabpad = " "; + }; + }; + }; + + languages = { + language = [ + { + name = "go"; + debugger = { + name = "go"; + transport = "tcp"; + command = "dlv"; + args = [ "connect" ]; + port-arg = "127.0.0.1:2345"; + templates = [{ + name = "connect"; + request = "launch"; + completion = []; + args = {}; + }]; + }; + } + { + name = "markdown"; + language-servers = [ "marksman" ]; + } + { + name = "dart"; + formatter = { command = "dart"; args = [ "format" "-l" "120" ]; }; + language-servers = [ "dart" ]; + } + { + name = "nix"; + language-servers = [ "nil" ]; + } + { + name = "zig"; + language-servers = [ "zls" ]; + debugger = { + name = "codelldb-dap"; + transport = "tcp"; + command = "codelldb"; + args = []; + port-arg = "--port {}"; + templates = [ + { + name = "launch"; + request = "launch"; + completion = [{ name = "binary"; completion = "filename"; }]; + args = { console = "internalConsole"; program = "{0}"; }; + } + { + name = "attach"; + request = "attach"; + completion = [ "pid" ]; + args = { console = "internalConsole"; pid = "{0}"; }; + } + { + name = "gdbserver attach"; + request = "attach"; + completion = [ + { name = "lldb connect url"; default = "connect://localhost:3333"; } + { name = "file"; completion = "filename"; } + "pid" + ]; + args = { + console = "internalConsole"; + attachCommands = [ + "platform select remote-gdb-server" + "platform connect {0}" + "file {1}" + "attach {2}" + ]; + }; + } + ]; + }; + } + { + name = "cyano"; + scope = "source.cyo"; + file-types = [ "cyo" ]; + language-servers = [ "ltex-ls" ]; + } + ]; + + language-server.ltex-ls = { + command = "ltex-ls"; + }; + }; + }; + + # + # CLI Tools + # + bat.enable = true; + + fzf = { + enable = true; + enableZshIntegration = true; + }; + + btop.enable = true; + + mpv.enable = true; + + # + # Launcher + # + wofi.enable = true; + }; +} diff --git a/frame12/modules/niri/niri_conf.nix b/frame12/modules/niri/niri_conf.nix index f71da8f..16ad196 100755 --- a/frame12/modules/niri/niri_conf.nix +++ b/frame12/modules/niri/niri_conf.nix @@ -65,7 +65,7 @@ in [ bash egl-wayland - foot + # foot is in programs.nix for Stylix theming git glib # gsettings grim @@ -83,10 +83,10 @@ in syncthingtray unstable.ghostty unstable.xwayland-satellite - waybar + # waybar is in programs.nix for Stylix theming wdisplays wl-clipboard - wofi + # wofi is in programs.nix for Stylix theming xdg-utils zsh # Fonts diff --git a/frame12/modules/niri/niri_home.nix b/frame12/modules/niri/niri_home.nix index 6adc12e..83b821d 100644 --- a/frame12/modules/niri/niri_home.nix +++ b/frame12/modules/niri/niri_home.nix @@ -1,5 +1,9 @@ { inputs, lib, config, pkgs, ... }: { + imports = [ + ../../../shared/modules/home-manager/waybar.nix + ]; + options.nirihome = { enable = lib.mkEnableOption "Enable niri home config"; homePackages = lib.mkOption { @@ -19,21 +23,16 @@ XDG_CURRENT_DESKTOP = "niri"; }; - home.pointerCursor = { - gtk.enable = true; - x11.enable = true; - name = "Bibata-Modern-Classic"; - package = pkgs.bibata-cursors; - size = 32; - }; + # Cursor is managed by Stylix (stylix.cursor in frame12/default.nix) + + # Waybar with Stylix theming + waybarConfig.enable = true; home.packages = with pkgs; lib.lists.flatten [ [ ### niri packages swaybg swaylock-effects - waybar - wofi # Etc gopsuinfo # For system stats in panel wl-clipboard # System clipboard diff --git a/frame12/wallpaper.png b/frame12/wallpaper.png new file mode 100644 index 0000000..afa330f Binary files /dev/null and b/frame12/wallpaper.png differ diff --git a/shared/dotfiles/ghostty/config b/shared/dotfiles/ghostty/config deleted file mode 100644 index 68c22ee..0000000 --- a/shared/dotfiles/ghostty/config +++ /dev/null @@ -1,41 +0,0 @@ -font-size = 14 -font-family = "Monaspace Xenon Var" -font-family-bold = "Monaspace Argon Var" -font-family-italic = "Monaspace Radon Var" -font-family-bold-italic = "Monaspace Krypton Var" - -font-variation = wght=400 -font-variation = wdth=100 -font-variation = slnt=-2 - -font-variation-bold = wght=600 -font-variation-bold = wdth=100 - -font-variation-italic = wght=400 -font-variation-italic = wdth=100 -font-variation-italic = slnt=-10 - -font-variation-bold-italic = wght=700 -font-variation-bold-italic = wdth=100 -font-variation-bold-italic = slnt=-3 - -# Liguratures -font-feature = +ss01, +ss02, +ss03, +ss04, +ss05, +ss06, +ss07, +ss08, +ss09, +ss10 -# Enables texture healing -font-feature = +calt -font-feature = +liga - -### -# Keybinds -### - -keybind = ctrl+shift+plus=increase_font_size:1 -# keybind = ctrl+minus=decrease_font_size:1 - -### -# Misc -### - -window-padding-x = 4 -window-padding-y = 4 -keybind = shift+enter=text:\n diff --git a/shared/dotfiles/swaync/config.json b/shared/dotfiles/swaync/config.json deleted file mode 100644 index f7c1eaa..0000000 --- a/shared/dotfiles/swaync/config.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "positionX": "center", - "positionY": "top", - "notification-window-width": 800 -} diff --git a/shared/dotfiles/swaync/style.css b/shared/dotfiles/swaync/style.css deleted file mode 100644 index 2cad1ab..0000000 --- a/shared/dotfiles/swaync/style.css +++ /dev/null @@ -1,342 +0,0 @@ -* { - all: unset; - font-size: 18px; - font-family: "Ubuntu Nerd Font"; - transition: 200ms; -} - -trough highlight { - background: #cad3f5; -} - -scale trough { - margin: 0rem 1rem; - background-color: #363a4f; - min-height: 8px; - min-width: 70px; -} - -slider { - background-color: #8aadf4; -} - -.floating-notifications.background .notification-row .notification-background { - box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.8), inset 0 0 0 1px #363a4f; - border-radius: 12.6px; - margin: 18px; - background-color: #24273a; - color: #cad3f5; - padding: 0; -} - -.floating-notifications.background .notification-row .notification-background .notification { - padding: 7px; - border-radius: 12.6px; -} - -.floating-notifications.background .notification-row .notification-background .notification.critical { - box-shadow: inset 0 0 7px 0 #ed8796; -} - -.floating-notifications.background .notification-row .notification-background .notification .notification-content { - margin: 7px; -} - -.floating-notifications.background .notification-row .notification-background .notification .notification-content .summary { - color: #cad3f5; -} - -.floating-notifications.background .notification-row .notification-background .notification .notification-content .time { - color: #a5adcb; -} - -.floating-notifications.background .notification-row .notification-background .notification .notification-content .body { - color: #cad3f5; -} - -.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * { - min-height: 3.4em; -} - -.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action { - border-radius: 7px; - color: #cad3f5; - background-color: #363a4f; - box-shadow: inset 0 0 0 1px #494d64; - margin: 7px; -} - -.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action:hover { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #363a4f; - color: #cad3f5; -} - -.floating-notifications.background .notification-row .notification-background .notification > *:last-child > * .notification-action:active { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #7dc4e4; - color: #cad3f5; -} - -.floating-notifications.background .notification-row .notification-background .close-button { - margin: 7px; - padding: 2px; - border-radius: 6.3px; - color: #24273a; - background-color: #ed8796; -} - -.floating-notifications.background .notification-row .notification-background .close-button:hover { - background-color: #ee99a0; - color: #24273a; -} - -.floating-notifications.background .notification-row .notification-background .close-button:active { - background-color: #ed8796; - color: #24273a; -} - -.control-center { - box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.8), inset 0 0 0 1px #363a4f; - border-radius: 12.6px; - margin: 18px; - background-color: #24273a; - color: #cad3f5; - padding: 14px; -} - -.control-center .widget-title > label { - color: #cad3f5; - font-size: 1.3em; -} - -.control-center .widget-title button { - border-radius: 7px; - color: #cad3f5; - background-color: #363a4f; - box-shadow: inset 0 0 0 1px #494d64; - padding: 8px; -} - -.control-center .widget-title button:hover { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #5b6078; - color: #cad3f5; -} - -.control-center .widget-title button:active { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #7dc4e4; - color: #24273a; -} - -.control-center .notification-row .notification-background { - border-radius: 7px; - color: #cad3f5; - background-color: #363a4f; - box-shadow: inset 0 0 0 1px #494d64; - margin-top: 14px; -} - -.control-center .notification-row .notification-background .notification { - padding: 7px; - border-radius: 7px; -} - -.control-center .notification-row .notification-background .notification.critical { - box-shadow: inset 0 0 7px 0 #ed8796; -} - -.control-center .notification-row .notification-background .notification .notification-content { - margin: 7px; -} - -.control-center .notification-row .notification-background .notification .notification-content .summary { - color: #cad3f5; -} - -.control-center .notification-row .notification-background .notification .notification-content .time { - color: #a5adcb; -} - -.control-center .notification-row .notification-background .notification .notification-content .body { - color: #cad3f5; -} - -.control-center .notification-row .notification-background .notification > *:last-child > * { - min-height: 3.4em; -} - -.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action { - border-radius: 7px; - color: #cad3f5; - background-color: #181926; - box-shadow: inset 0 0 0 1px #494d64; - margin: 7px; -} - -.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action:hover { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #363a4f; - color: #cad3f5; -} - -.control-center .notification-row .notification-background .notification > *:last-child > * .notification-action:active { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #7dc4e4; - color: #cad3f5; -} - -.control-center .notification-row .notification-background .close-button { - margin: 7px; - padding: 2px; - border-radius: 6.3px; - color: #24273a; - background-color: #ee99a0; -} - -.close-button { - border-radius: 6.3px; -} - -.control-center .notification-row .notification-background .close-button:hover { - background-color: #ed8796; - color: #24273a; -} - -.control-center .notification-row .notification-background .close-button:active { - background-color: #ed8796; - color: #24273a; -} - -.control-center .notification-row .notification-background:hover { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #8087a2; - color: #cad3f5; -} - -.control-center .notification-row .notification-background:active { - box-shadow: inset 0 0 0 1px #494d64; - background-color: #7dc4e4; - color: #cad3f5; -} - -.notification.critical progress { - background-color: #ed8796; -} - -.notification.low progress, -.notification.normal progress { - background-color: #8aadf4; -} - -.control-center-dnd { - margin-top: 5px; - border-radius: 8px; - background: #363a4f; - border: 1px solid #494d64; - box-shadow: none; -} - -.control-center-dnd:checked { - background: #363a4f; -} - -.control-center-dnd slider { - background: #494d64; - border-radius: 8px; -} - -.widget-dnd { - margin: 0px; - font-size: 1.1rem; -} - -.widget-dnd > switch { - font-size: initial; - border-radius: 8px; - background: #363a4f; - border: 1px solid #494d64; - box-shadow: none; -} - -.widget-dnd > switch:checked { - background: #363a4f; -} - -.widget-dnd > switch slider { - background: #494d64; - border-radius: 8px; - border: 1px solid #6e738d; -} - -.widget-mpris .widget-mpris-player { - background: #363a4f; - padding: 7px; -} - -.widget-mpris .widget-mpris-title { - font-size: 1.2rem; -} - -.widget-mpris .widget-mpris-subtitle { - font-size: 0.8rem; -} - -.widget-menubar > box > .menu-button-bar > button > label { - font-size: 3rem; - padding: 0.5rem 2rem; -} - -.widget-menubar > box > .menu-button-bar > :last-child { - color: #ed8796; -} - -.power-buttons button:hover, -.powermode-buttons button:hover, -.screenshot-buttons button:hover { - background: #363a4f; -} - -.control-center .widget-label > label { - color: #cad3f5; - font-size: 2rem; -} - -.widget-buttons-grid { - padding-top: 1rem; -} - -.widget-buttons-grid > flowbox > flowboxchild > button label { - font-size: 2.5rem; -} - -.widget-volume { - padding-top: 1rem; -} - -.widget-volume label { - font-size: 1.5rem; - color: #7dc4e4; -} - -.widget-volume trough highlight { - background: #7dc4e4; -} - -.widget-backlight trough highlight { - background: #eed49f; -} - -.widget-backlight label { - font-size: 1.5rem; - color: #eed49f; -} - -.widget-backlight .KB { - padding-bottom: 1rem; -} - -.image { - padding-right: 0.5rem; -} diff --git a/shared/linked-dotfiles/helix/config.toml b/shared/linked-dotfiles/helix/config.toml deleted file mode 100644 index b8fb1ea..0000000 --- a/shared/linked-dotfiles/helix/config.toml +++ /dev/null @@ -1,190 +0,0 @@ -# Theme -theme = "catppuccin_macchiato_minimal" - -[keys.normal] - -# Navigation -n = "move_char_left" # Maps the 'a' key to the move_char_left command -i = "move_visual_line_down" -e = "move_visual_line_up" -o = "move_char_right" -"S-tab" = "jump_backward" - -I = ["page_cursor_half_down", "align_view_center"] -E = ["page_cursor_half_up", "align_view_center"] - -# Modes -h = "insert_mode" -H = "insert_at_line_start" -l = "open_below" -L = "open_above" - -# Search -k = "search_next" -K = "search_prev" - -# Selection -C-s = "split_selection_on_newline" -C-minus = "merge_selections" -C-_ = "merge_consecutive_selections" -"C-;" = "flip_selections" -"C-:" = "ensure_selections_forward" -"C-," = "remove_primary_selection" -C-c = "change_selection_noyank" -C-d = "delete_selection_noyank" -"C-(" = "rotate_selection_contents_backward" -"C-)" = "rotate_selection_contents_forward" -C-x = "shrink_to_line_bounds" -C-J = "join_selections_space" -C-K = "remove_selections" -C-o = "expand_selection" -C-i = "shrink_selection" -C-p = "select_prev_sibling" -C-n = "select_next_sibling" - -# Misc -"C-/" = "toggle_comments" -"@" = ":append-output git config get user.email" - -[keys.normal.space] -# Git blame for line -B = ":sh git log -n 5 --format='format:%%h (%%an: %%ar) %%s' --no-patch -L%{cursor_line},+1:%{buffer_name}" -x = ":write-buffer-close" -X = ":write-quit-all" -o = ":config-open" -h = "hover" -k = "select_references_to_symbol_under_cursor" - -[keys.normal.g] -"/" = "goto_next_buffer" -h = "goto_previous_buffer" -n = ["collapse_selection", "extend_to_line_start"] -o = ["collapse_selection", "extend_to_line_end"] -e = "move_line_up" -i = "move_line_down" -l = "goto_last_line" - -p = "no_op" -k = "no_op" -j = "no_op" - -[keys.normal.m] -m = ["select_mode", "match_brackets", "normal_mode"] - -[keys.select] -n = "extend_char_left" -i = "extend_line_down" -e = "extend_line_up" -o = "extend_char_right" -I = ["page_cursor_half_down", "align_view_center"] -E = ["page_cursor_half_up", "align_view_center"] - -[keys.select.g] -"/" = "goto_next_buffer" -h = "goto_previous_buffer" -n = "goto_line_start" -o = "goto_line_end" -e = "move_line_up" -i = "move_line_down" -l = "goto_last_line" - -p = "no_op" -k = "no_op" -j = "no_op" - -# Window mode -[keys.normal."C-w"] -h = "hsplit" -C-h = "hsplit" -n = "jump_view_left" -C-n = "jump_view_left" -i = "jump_view_down" -I = "swap_view_down" -C-i = "jump_view_down" -e = "jump_view_up" -E = "swap_view_up" -C-e = "jump_view_up" -o = "jump_view_right" -O = "swap_view_right" -C-o = "jump_view_right" - -# Remove old -s = "no_op" -C-s = "no_op" -H = "no_op" -j = "no_op" -J = "no_op" -C-j = "no_op" -k = "no_op" -K = "no_op" -C-k = "no_op" -l = "no_op" -L = "no_op" -C-l = "no_op" - -[editor] -auto-format = true -auto-save = true -bufferline = "always" -color-modes = true # color each mode differently in statusline -completion-timeout = 5 -cursorcolumn = true -cursorline = true -indent-heuristic = "tree-sitter" -line-number = "relative" -rulers = [120] -text-width = 120 -end-of-line-diagnostics = "hint" - -[editor.cursor-shape] -insert = "bar" -normal = "block" -select = "underline" - -[editor.file-picker] -hidden = false - -[editor.indent-guides] -render = true - -[editor.inline-diagnostics] -cursor-line = "warning" -other-lines = "disable" -prefix-len = 5 -max-diagnostics = 1 -max-wrap = 30 - -[editor.lsp] -display-messages = true -display-inlay-hints = true - -[editor.soft-wrap] -enable = true -max-wrap = 30 - -[editor.statusline] -left = ["mode", "file-modification-indicator", "spinner", "version-control"] -center = ["file-name"] -right = ["diagnostics", "selections", "register", "position", "file-encoding"] -mode.normal = "Normal" -mode.insert = "Insert" -mode.select = "Select" - -[editor.whitespace.render] -space = "all" -tab = "all" -tabpad = "all" -newline = "none" -nbsp = "none" - -[editor.whitespace.characters] -space = " " -# space = "·" -tab = "⇀" -tabpad = " " - - -#w = "move_line_up" # Maps the 'w' key move_line_up -#"C-S-esc" = "extend_line" # Maps Ctrl-Shift-Escape to extend_line -#g = { a = "code_action" } # Maps `ga` to show possible code actions -#"ret" = ["open_below", "normal_mode"] # Maps the enter key to open_below then re-enter normal mode diff --git a/shared/linked-dotfiles/helix/languages.toml b/shared/linked-dotfiles/helix/languages.toml deleted file mode 100644 index 8ed25e3..0000000 --- a/shared/linked-dotfiles/helix/languages.toml +++ /dev/null @@ -1,81 +0,0 @@ -### -### Configuration for languages -### - -[[language]] -name = "go" - -[language.debugger] -name = "go" -transport = "tcp" -command = "dlv" -args = ["connect"] -port-arg = "127.0.0.1:2345" - -[[language.debugger.templates]] -name = "connect" -request = "launch" -completion = [] -args = {} -# completion = [ {name = "port", default = "2345"} ] -# args = { port = "{0}" } - -[[language]] -name = "markdown" -language-servers = ["marksman"] - -# Change dart format to 120 lines -[[language]] -name = "dart" -formatter = {command = "dart", args = ["format", "-l", "120"]} -language-servers = ["dart"] - -[[language]] -name = "nix" -language-servers = ["nil"] - -# -# Zig configuration -# -[[language]] -name = "zig" -language-servers = ["zls"] - -[language.debugger] -name = "codelldb-dap" -transport = "tcp" -command = "codelldb" -args = [] -port-arg = "--port {}" - -[[language.debugger.templates]] -name = "launch" -request = "launch" -completion = [ { name = "binary", completion = "filename" } ] -args = { console = "internalConsole", program = "{0}" } - -[[language.debugger.templates]] -name = "attach" -request = "attach" -completion = [ "pid" ] -args = { console = "internalConsole", pid = "{0}" } - -[[language.debugger.templates]] -name = "gdbserver attach" -request = "attach" -completion = [ { name = "lldb connect url", default = "connect://localhost:3333" }, { name = "file", completion = "filename" }, "pid" ] -args = { console = "internalConsole", attachCommands = [ "platform select remote-gdb-server", "platform connect {0}", "file {1}", "attach {2}" ] } - -# -# cyo custom def -# -[[language]] -name = "cyano" -scope = "source.cyo" -file-types = ["cyo"] -# Spell checker -language-servers = ["ltex-ls"] - -[language-server.ltex-ls] -command = "ltex-ls" - diff --git a/shared/linked-dotfiles/helix/themes/catppuccin_macchiato_minimal.toml b/shared/linked-dotfiles/helix/themes/catppuccin_macchiato_minimal.toml deleted file mode 100644 index baca34f..0000000 --- a/shared/linked-dotfiles/helix/themes/catppuccin_macchiato_minimal.toml +++ /dev/null @@ -1,149 +0,0 @@ -# Catppuccin Macchiato Minimal - Judicious Syntax Highlighting -# Uses only 4 colors for syntax -# Functions and variables remain plain text for reduced visual noise - -"ui.background" = { bg = "base" } -"ui.virtual" = { fg = "surface0" } -"ui.virtual.ruler" = { bg = "surface0" } -"ui.virtual.indent-guide" = { fg = "surface0" } -"ui.virtual.inlay-hint" = { fg = "overlay1", bg = "mantle", modifiers = ["italic"] } -"ui.virtual.jump-label" = { fg = "red", modifiers = ["bold"] } - -"ui.selection" = { bg = "surface1" } -"ui.selection.primary" = { bg = "surface2" } - -"ui.cursor" = { fg = "base", bg = "lavender" } -"ui.cursor.primary" = { fg = "base", bg = "lavender" } -"ui.cursor.match" = { fg = "peach", modifiers = ["bold"] } -"ui.cursorline.primary" = { bg = "surface0" } -"ui.cursorcolumn.primary" = { bg = "surface0" } - -"ui.linenr" = { fg = "surface1" } -"ui.linenr.selected" = { fg = "lavender", modifiers = ["bold"] } - -"ui.statusline" = { fg = "text", bg = "mantle" } -"ui.statusline.inactive" = { fg = "overlay0", bg = "mantle" } -"ui.statusline.normal" = { fg = "base", bg = "lavender", modifiers = ["bold"] } -"ui.statusline.insert" = { fg = "base", bg = "green", modifiers = ["bold"] } -"ui.statusline.select" = { fg = "base", bg = "mauve", modifiers = ["bold"] } - -"ui.bufferline" = { fg = "overlay0", bg = "mantle" } -"ui.bufferline.active" = { fg = "lavender", bg = "base", modifiers = ["bold"] } - -"ui.help" = { fg = "text", bg = "surface0" } -"ui.text" = "text" -"ui.text.focus" = { fg = "text", bg = "surface0" } -"ui.text.inactive" = "overlay1" - -"ui.menu" = { fg = "text", bg = "surface0" } -"ui.menu.selected" = { fg = "text", bg = "surface1", modifiers = ["bold"] } -"ui.menu.scroll" = { fg = "overlay0", bg = "surface0" } - -"ui.popup" = { fg = "text", bg = "surface0" } -"ui.window" = { fg = "base" } - -"diagnostic.error" = { underline = { color = "red", style = "curl" } } -"diagnostic.warning" = { underline = { color = "yellow", style = "curl" } } -"diagnostic.info" = { underline = { color = "sky", style = "curl" } } -"diagnostic.hint" = { underline = { color = "teal", style = "curl" } } -"diagnostic.unnecessary" = { modifiers = ["dim"] } -"diagnostic.deprecated" = { modifiers = ["crossed_out"] } - -"error" = "red" -"warning" = "yellow" -"info" = "sky" -"hint" = "teal" - -"diff.plus" = "green" -"diff.minus" = "red" -"diff.delta" = "yellow" - -"markup.heading" = { fg = "lavender", modifiers = ["bold"] } -"markup.list" = "mauve" -"markup.bold" = { modifiers = ["bold"] } -"markup.italic" = { modifiers = ["italic"] } -"markup.strikethrough" = { modifiers = ["crossed_out"] } -"markup.link.url" = { fg = "blue", modifiers = ["underlined"] } -"markup.link.text" = "mauve" -"markup.quote" = "green" -"markup.raw" = "green" - -# Minimal syntax highlighting - only 4 colors used -"comment" = "yellow" # Comments pop - -"keyword" = { fg = "mauve", modifiers = ["italic"] } # Keywords highlighted and italic -"keyword.control" = { fg = "mauve", modifiers = ["italic"] } -"keyword.directive" = { fg = "mauve", modifiers = ["italic"] } -"keyword.function" = { fg = "mauve", modifiers = ["italic"] } -"keyword.operator" = { fg = "mauve", modifiers = ["italic"] } -"keyword.return" = { fg = "mauve", modifiers = ["italic"] } -"keyword.storage" = { fg = "mauve", modifiers = ["italic"] } - -"string" = "green" # Strings highlighted -"string.regexp" = "peach" -"string.special" = "green" - -"constant.numeric" = "peach" # Numbers highlighted -"constant.builtin" = "peach" -"constant.character.escape" = "peach" - -# Everything else remains plain text -"function" = "text" # Functions are plain text -"function.builtin" = "text" -"function.method" = "text" -"function.macro" = "text" - -"variable" = "text" # Variables are plain text -"variable.builtin" = "text" -"variable.parameter" = "text" -"variable.other.member" = "text" - -"type" = { fg = "lavender", modifiers = ["italic"]} # Types are slightly highlighted -"type.builtin" = "lavender" - -"constructor" = "text" # Constructors are plain text - -"attribute" = "text" -"label" = "text" -"namespace" = "text" -"tag" = "text" - -# Top-level declarations get keyword color -"function.definition" = { fg = "flamingo", modifiers = ["bold"] } -"type.definition" = { fg = "flamingo", modifiers = ["bold"] } - -# Punctuation is slightly dimmed but still readable -"punctuation" = "subtext0" -"punctuation.bracket" = "subtext0" -"punctuation.delimiter" = "subtext0" -"punctuation.special" = "subtext0" - -"operator" = "subtext0" # Operators slightly dimmed - -[palette] -rosewater = "#f4dbd6" -flamingo = "#f0c6c6" -pink = "#f5bde6" -mauve = "#c6a0f6" -red = "#ed8796" -maroon = "#ee99a0" -peach = "#f5a97f" -yellow = "#eed49f" -green = "#a6da95" -teal = "#8bd5ca" -sky = "#91d7e3" -sapphire = "#7dc4e4" -blue = "#8aadf4" -lavender = "#b7bdf8" -text = "#cad3f5" -subtext1 = "#b8c0e0" -subtext0 = "#a5adcb" -overlay2 = "#939ab7" -overlay1 = "#8087a2" -overlay0 = "#6e738d" -surface2 = "#5b6078" -surface1 = "#494d64" -surface0 = "#363a4f" -base = "#24273a" -mantle = "#1e2030" -crust = "#181926" diff --git a/shared/modules/apps/firefox/firefox.nix b/shared/modules/apps/firefox/firefox.nix index 10d43e3..1df6339 100644 --- a/shared/modules/apps/firefox/firefox.nix +++ b/shared/modules/apps/firefox/firefox.nix @@ -11,6 +11,9 @@ in enable = lib.mkEnableOption "enable firefox browser"; }; config = lib.mkIf cfg.enable { + # Tell Stylix which Firefox profile to theme + stylix.targets.firefox.profileNames = [ "default" ]; + programs.firefox = { # Add pipewire support # package = (pkgs.wrapFirefox (pkgs.firefox-unwrapped.override { pipewireSupport = true;}) {}); diff --git a/shared/modules/home-manager/waybar.nix b/shared/modules/home-manager/waybar.nix new file mode 100644 index 0000000..07dbd94 --- /dev/null +++ b/shared/modules/home-manager/waybar.nix @@ -0,0 +1,534 @@ +# Shared Waybar configuration with Stylix theming +# Parameterized for use across multiple machines +{ config, pkgs, lib, ... }: + +let + cfg = config.waybarConfig; +in +{ + options.waybarConfig = { + enable = lib.mkEnableOption "Waybar with Stylix theming"; + + terminal = lib.mkOption { + type = lib.types.str; + default = "ghostty"; + description = "Terminal emulator to use for on-click commands"; + }; + + launcher = lib.mkOption { + type = lib.types.str; + default = "wofi --show=drun"; + description = "Application launcher command"; + }; + + fontSize = lib.mkOption { + type = lib.types.int; + default = 16; + description = "Base font size for waybar"; + }; + + font = lib.mkOption { + type = lib.types.str; + default = "Overpass Nerd Font"; + description = "Font family for waybar"; + }; + + position = lib.mkOption { + type = lib.types.enum [ "top" "bottom" ]; + default = "top"; + description = "Bar position"; + }; + + margin = lib.mkOption { + type = lib.types.int; + default = 3; + description = "Margin around the bar in pixels"; + }; + + extraModulesLeft = lib.mkOption { + type = lib.types.listOf lib.types.str; + default = []; + description = "Additional modules to add to the left side"; + }; + + extraModulesRight = lib.mkOption { + type = lib.types.listOf lib.types.str; + default = []; + description = "Additional modules to add to the right side"; + }; + + windowRewriteRules = lib.mkOption { + type = lib.types.attrsOf lib.types.str; + default = {}; + description = "Additional window title rewrite rules"; + }; + + workspaceIcons = lib.mkOption { + type = lib.types.attrsOf lib.types.str; + default = {}; + description = "Additional workspace icons"; + }; + }; + + config = lib.mkIf cfg.enable { + programs.waybar = { + enable = true; + + settings = { + mainBar = { + layer = "top"; + position = cfg.position; + margin-top = cfg.margin; + margin-left = cfg.margin; + margin-right = cfg.margin; + margin-bottom = cfg.margin; + + modules-left = [ + "custom/launcher" + "niri/workspaces" + "niri/window" + ] ++ cfg.extraModulesLeft; + + modules-right = cfg.extraModulesRight ++ [ + "clock" + "custom/storage" + "memory" + "cpu" + "battery" + "custom/wlsunset" + "tray" + "custom/power" + ]; + + "idle_inhibitor" = { + format = "{icon} "; + format-icons = { + activated = ""; + deactivated = ""; + }; + }; + + battery = { + states = { + warning = 30; + critical = 15; + }; + format = "{icon} {capacity}%"; + format-charging = "{capacity}% 󰂄"; + format-plugged = "{capacity}% "; + format-icons = [ "" "" "" "" "" ]; + }; + + clock = { + interval = 1; + format = "{:%I:%M.%S %p}"; + tooltip-format = "{:%e %B %Y}"; + }; + + cpu = { + interval = 5; + format = " {usage}%"; + states = { + warning = 70; + critical = 90; + }; + on-click = "${cfg.terminal} -e 'htop'"; + }; + + memory = { + interval = 5; + format = " {}%"; + on-click = "${cfg.terminal} -e 'htop'"; + states = { + warning = 70; + critical = 90; + }; + }; + + network = { + interval = 5; + format-wifi = ""; + format-ethernet = " {ifname}: {ipaddr}/{cidr}"; + format-disconnected = "⚠ Disconnected"; + tooltip-format = "{essid} - {ifname}:{ipaddr} {bandwidthUpBytes} {bandwidthDownBytes}"; + on-click = "${cfg.terminal} -e 'nmtui'"; + }; + + "niri/window" = { + format = "{title}"; + icon = true; + icon-size = 20; + rewrite = { + # Firefox + "(.*) — Mozilla Firefox" = " $1"; + "(.*) - Mozilla Firefox" = " $1"; + "Mozilla Firefox" = " Firefox"; + # Chrome/Chromium + "(.*) - Google Chrome" = " $1"; + "(.*) - Chromium" = " $1"; + "Google Chrome" = " Chrome"; + "Chromium" = " Chromium"; + # Terminals + "(.*) - zsh" = " $1"; + "(.*) - bash" = " $1"; + "(.*) - fish" = " $1"; + "ghostty" = " Terminal"; + "kitty" = " Terminal"; + "alacritty" = " Terminal"; + # Editors/IDEs + "(.*) - Visual Studio Code" = " $1"; + "(.*) - Code" = " $1"; + "(.*) - Vim" = " $1"; + "(.*) - Neovim" = " $1"; + "(.*) - Emacs" = " $1"; + "Visual Studio Code" = " VS Code"; + # File managers + "(.*)Nautilus" = " Files: $1"; + "Files" = " Files"; + "Thunar" = " Files"; + "Dolphin" = " Files"; + # Communication + "Slack (.*)" = " $1"; + "Slack" = " Slack"; + "Signal" = " Signal"; + "Discord" = " Discord"; + "Telegram" = " Telegram"; + # Media + "Spotify" = " Spotify"; + "Steam" = " Steam"; + "(.*) - YouTube" = "󰗃 $1"; + "VLC media player" = "󰕼 VLC"; + # Dev tools + "(.*) - GitHub" = " $1"; + "GitKraken" = " GitKraken"; + "Postman" = " Postman"; + # System + "System Monitor" = " System Monitor"; + "Task Manager" = " Task Manager"; + "Settings" = " Settings"; + "Control Panel" = " Settings"; + # Office + "(.*) - LibreOffice Writer" = " $1"; + "(.*) - LibreOffice Calc" = " $1"; + "(.*) - LibreOffice Impress" = " $1"; + # Fallbacks + "^(.*) - .*$" = "$1"; + "^(.*) | .*$" = "$1"; + "^$" = "Desktop"; + } // cfg.windowRewriteRules; + }; + + "niri/workspaces" = { + disable-click = false; + disable-markup = false; + all-outputs = true; + format = " {icon} "; + format-icons = { + term = ""; + net = ""; + chat = "󰭻"; + scratch = ""; + "1" = " 1"; + "2" = " 2"; + "3" = " 3"; + "4" = " 4"; + "5" = " 5"; + "6" = " 6"; + "7" = " 7"; + "8" = " 8"; + "9" = " 9"; + } // cfg.workspaceIcons; + }; + + pulseaudio = { + scroll-step = 1; + format = "{icon} {volume}%"; + format-bluetooth = "{volume}% {icon} {format_source}"; + format-bluetooth-muted = " {icon} {format_source}"; + format-muted = " {format_source}"; + format-source = "{volume}% "; + format-source-muted = ""; + format-icons = { + headphone = [ "" "" "" "" "" ]; + hands-free = ""; + headset = ""; + phone = ""; + portable = ""; + car = ""; + default = [ "" "" "" ]; + }; + on-click = "pavucontrol"; + on-scroll-up = "pactl set-sink-volume @DEFAULT_SINK@ +2%"; + on-scroll-down = "pactl set-sink-volume @DEFAULT_SINK@ -2%"; + }; + + tray = { + icon-size = 20; + spacing = 10; + }; + + backlight = { + format = "{icon} {percent}%"; + format-icons = [ "󰹐" "󱩏" "󱩑" "󱩓" "󱩕" "󰛨" ]; + on-scroll-down = "brightnessctl -c backlight set 1%-"; + on-scroll-up = "brightnessctl -c backlight set +1%"; + min-brightness = 1; + }; + + "custom/storage" = { + format = "{icon} {percentage}%"; + format-icons = { + default = ""; + warning = ""; + critical = ""; + }; + exec = ''usage=$(df / --output=pcent | tail -n1 | tr -d ' %'); if [ $usage -ge 90 ]; then class="critical"; elif [ $usage -ge 75 ]; then class="warning"; else class="default"; fi; echo "{\"percentage\":$usage,\"class\":\"$class\"}"''; + return-type = "json"; + interval = 30; + tooltip-format = "Root filesystem: {percentage}% used"; + }; + + "custom/launcher" = { + format = " "; + on-click = cfg.launcher; + tooltip = false; + }; + + "custom/wlsunset" = { + format = "{}"; + exec = "if systemctl --user is-active --quiet wlsunset; then echo '󰖜'; else echo '󰖚'; fi"; + on-click = "if systemctl --user is-active --quiet wlsunset; then systemctl --user stop wlsunset; else systemctl --user start wlsunset; fi; pkill -SIGRTMIN+8 waybar"; + interval = "once"; + signal = 8; + tooltip = false; + }; + + "custom/power" = { + format = "⏻"; + on-click = "entries='Logout Suspend Reboot Shutdown'; selected=$(printf '%s\\n' $entries | wofi --show=dmenu | awk '{print tolower($1)}'); case $selected in logout) niri msg action quit;; suspend) systemctl suspend;; reboot) systemctl reboot;; shutdown) systemctl poweroff -i;; esac"; + tooltip = false; + }; + }; + }; + + # Stylix provides @define-color variables for base16 colors + style = '' + /* Keyframes */ + @keyframes blink-warning { + 70% { color: @base05; } + to { color: @base05; background-color: @base00; } + } + + @keyframes blink-critical { + 70% { color: @base05; } + to { color: @base05; background-color: @base01; } + } + + /* Reset all styles */ + * { + border: none; + border-radius: 0; + min-height: 30px; + margin: 0px; + padding: 0px; + } + + /* The whole bar */ + #waybar { + background: transparent; + background-color: transparent; + font-family: ${cfg.font}; + font-size: ${toString cfg.fontSize}px; + color: @base05; + } + + #taskbar { + background: transparent; + } + + #taskbar button { + padding-left: 3px; + padding-right: 3px; + margin-left: 3px; + margin-right: 3px; + border-bottom: 2px solid; + } + + #taskbar button.active { + color: @base0B; + } + + .modules-left, + .modules-right { + background: transparent; + background-color: @base00; + border-radius: 20px; + padding: 0px 6px 0px 6px; + border-style: solid; + border-width: 3px; + border-color: @base02; + } + + .modules-center { + background: transparent; + border: none; + padding: 0; + min-height: 0; + } + + #backlight, + #battery, + #clock, + #cpu, + #custom-storage, + #custom-keyboard-layout, + #custom-PBPbattery, + #custom-weather, + #idle_inhibitor, + #memory, + #mode, + #network, + #pulseaudio, + #temperature, + #tray { + padding: 0.5rem 0.6rem; + margin: 1px 0px; + } + + #clock { + margin-left: 5px; + margin-right: 5px; + min-width: 140px; + } + + #backlight, + #battery, + #cpu, + #custom-storage, + #memory, + #network, + #pulseaudio, + #temperature { + min-width: 90px; + } + + #battery { + animation-timing-function: linear; + animation-iteration-count: infinite; + animation-direction: alternate; + } + + #battery.warning, + #custom-storage.warning { + color: @base09; + } + + #battery.critical, + #custom-storage.critical { + color: @base08; + } + + #battery.warning.discharging { + animation-name: blink-warning; + animation-duration: 3s; + } + + #battery.critical.discharging { + animation-name: blink-critical; + animation-duration: 2s; + } + + #cpu.warning { + color: @base09; + } + + #cpu.critical { + color: @base08; + } + + #memory { + animation-timing-function: linear; + animation-iteration-count: infinite; + animation-direction: alternate; + } + + #memory.warning { + color: @base09; + } + + #memory.critical { + color: @base08; + animation-name: blink-critical; + animation-duration: 2s; + padding-left: 5px; + padding-right: 5px; + } + + #mode { + background: @base03; + border-bottom: 3px transparent; + color: @base05; + margin-left: 5px; + margin-right: 5px; + border-radius: 20px; + } + + #network.disconnected { + color: @base09; + } + + #pulseaudio { + padding-top: 6px; + } + + #pulseaudio.muted { + color: @base0C; + } + + #temperature.critical { + color: @base08; + } + + #window { + font-weight: bold; + margin-left: 20px; + margin-right: 10px; + } + + #workspaces { + font-size: ${toString cfg.fontSize}px; + } + + #workspaces button { + margin-bottom: 0px; + padding: 0px; + } + + #workspaces button.active { + border-bottom: 3px solid @base0D; + color: @base0B; + } + + #workspaces button.urgent { + border-color: @base0D; + color: @base0A; + } + + #custom-power { + margin-left: 15px; + margin-right: 15px; + color: @base09; + } + + #custom-launcher { + margin-left: 15px; + margin-right: 10px; + } + + #backlight.icon { + padding-right: 1px; + } + ''; + }; + }; +}