diff --git a/flake.nix b/flake.nix index 845a119..4d2a74e 100755 --- a/flake.nix +++ b/flake.nix @@ -278,6 +278,36 @@ url = "github:LnL7/nix-darwin"; inputs.nixpkgs.follows = "desktop-nixpkgs"; }; + + ##################################################### + # Macbook Nix # + ##################################################### + + # nixpgs + mac-nixpkgs = { + url = "github:NixOS/nixpkgs/nixos-unstable"; + }; + + mac-nixos-apple-silicon = { + url = "github:nix-community/nixos-apple-silicon"; + }; + + # Home Manager + mac-home-manager = { + url = "github:nix-community/home-manager"; + inputs.nixpkgs.follows = "mac-nixpkgs"; + }; + + # Impermenance + mac-impermanence = { + url = "github:nix-community/impermanence"; + }; + + # Sops-nix + mac-sops-nix = { + url = "github:Mic92/sops-nix"; + inputs.nixpkgs.follows = "mac-nixpkgs"; + }; ##################################################### # Common # @@ -355,6 +385,13 @@ # MacBook nix-darwin, + # MacBook Nix + mac-nixpkgs, + mac-nixos-apple-silicon, + mac-home-manager, + mac-impermanence, + mac-sops-nix, + # Common nixpkgs-unstable, nixpkgs-stable, @@ -680,6 +717,61 @@ ]; }; + # MacBook Nix + "macbook-pro-nixos" = mac-nixpkgs.lib.nixosSystem { + system = "aarch64-linux"; + specialArgs = { + inherit inputs outputs; + }; + modules = [ + ./hosts/base/base-nogui + ./hosts/base/base-gui + ./hosts/mac-nixos/configuration.nix + + ./modules/desktop-environments/hyprland + + # Apple Silicon Support + mac-nixos-apple-silicon.nixosModules.default + + # Impermanence + mac-impermanence.nixosModules.impermanence + ./modules/impermanence + + mac-sops-nix.nixosModules.sops + + # Home Manager + mac-home-manager.nixosModules.home-manager + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.users.matt = + { ... }: + { + imports = [ + ./hosts/mac/home.nix + ./modules/home/defaults.nix + ./modules/home/git.nix + ./modules/home/gnome.nix + ./modules/home/librewolf.nix + ./modules/home/office.nix + ./modules/home/shell.nix + ./modules/home/vscode.nix + mac-sops-nix.homeManagerModules.sops + ]; + }; + home-manager.users.root = + { ... }: + { + imports = [ + ./modules/root-user + mac-sops-nix.homeManagerModules.sops + ]; + }; + home-manager.backupFileExtension = "backup"; + } + ]; + }; + # home assistant # "jallen-hass" = nixpkgs-unstable.lib.nixosSystem { # system = "x86_64-linux"; diff --git a/hosts/mac-nixos/configuration.nix b/hosts/mac-nixos/configuration.nix index 11990a7..752c873 100755 --- a/hosts/mac-nixos/configuration.nix +++ b/hosts/mac-nixos/configuration.nix @@ -10,15 +10,13 @@ in imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix - ../default.nix -# ./gnome -# ./cosmic ]; hardware.asahi = { enable = true; useExperimentalGPUDriver = true; peripheralFirmwareDirectory = ./firmware; + # extractPeripheralFirmware = false; setupAsahiSound = true; }; @@ -39,7 +37,7 @@ in # Networking configs networking = { - hostName = "mac-nixos"; + hostName = "macbook-pro-nixos"; # Enable Network Manager networkmanager = { diff --git a/hosts/mac-nixos/cosmic/default.nix b/hosts/mac-nixos/cosmic/default.nix deleted file mode 100755 index 50fb6ef..0000000 --- a/hosts/mac-nixos/cosmic/default.nix +++ /dev/null @@ -1,14 +0,0 @@ -{ pkgs, ... }: -{ - specialisation.cosmic.configuration = { - services = { - desktopManager.cosmic.enable = true; - displayManager.cosmic-greeter.enable = true; - - # disable plasma - displayManager.sddm.enable = false; - displayManager.sddm.wayland.enable = false; - desktopManager.plasma6.enable = false; - }; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/gnome/default.nix b/hosts/mac-nixos/gnome/default.nix deleted file mode 100755 index b3496cc..0000000 --- a/hosts/mac-nixos/gnome/default.nix +++ /dev/null @@ -1,30 +0,0 @@ -{ pkgs, ... }: -{ - specialisation.gnome.configuration = { - - - home-manager.users.matt = import ./home.nix; - - services = { - desktopManager.gnome.enable = true; - - # Enable Desktop Environment. - displayManager = { - gdm.enable = true; - gdm.wayland = true; - }; - - displayManager.defaultSession = "gnome"; - - # Enable Flatpak - flatpak.enable = false; - - # disable plasma - displayManager.sddm.enable = false; - displayManager.sddm.wayland.enable = false; - desktopManager.plasma6.enable = false; - }; - - # xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; - }; -} diff --git a/hosts/mac-nixos/gnome/home.nix b/hosts/mac-nixos/gnome/home.nix deleted file mode 100755 index eb50f1f..0000000 --- a/hosts/mac-nixos/gnome/home.nix +++ /dev/null @@ -1,42 +0,0 @@ -{ lib, pkgs, ... }: -{ - home.packages = with pkgs; [ - nixfmt-rfc-style - deadnix - gdm - gnomeExtensions.dash-to-dock - gnomeExtensions.arcmenu - gnomeExtensions.appindicator - gnomeExtensions.tiling-assistant - gnome-tweaks - papirus-icon-theme - ]; - - dconf = { - enable = true; - settings = { - "org/gnome/desktop/interface".clock-format = "12h"; - "org/gnome/desktop/interface".color-scheme = "prefer-dark"; - "org/gnome/desktop/interface".enable-hot-corners = false; - "org/gnome/desktop/interface".font-antialiasing = "grayscale"; - "org/gnome/desktop/interface".font-hinting = "slight"; - "org/gnome/desktop/interface".icon-theme = lib.mkDefault "Papirus-Dark"; - "org/gnome/desktop/peripherals/mouse".accel-profile = "flat"; - "org/gnome/desktop/peripherals/touchpad".two-finger-scrolling-enabled = true; - "org/gnome/desktop/peripherals/touchpad".tap-to-click = true; - "org/gnome/mutter".experimental-features = [ - "scale-monitor-framebuffer" - "variable-refresh-rate" - ]; - "org/gnome/tweaks".show-extensions-notice = false; - "org/gnome/shell".enabled-extensions = [ - "appindicatorsupport@rgcjonas.gmail.com" - "arcmenu@arcmenu.com" - "user-theme@gnome-shell-extensions.gcampax.github.com" - "dash-to-dock@micxgx.gmail.com" - "tiling-assistant@leleat-on-github" - ]; - "org/gtk/settings/file-chooser".clock-format = "12h"; - }; - }; -} diff --git a/hosts/mac-nixos/home.nix b/hosts/mac-nixos/home.nix index 347d84d..7686b4a 100755 --- a/hosts/mac-nixos/home.nix +++ b/hosts/mac-nixos/home.nix @@ -1,117 +1,7 @@ { pkgs, ... }: -let - gtkThemeSize = "compact"; - gtkThemeAccent = "all"; - gtkThemeVariant = "nord"; - gtkThemeColor = "dark"; - gtkTheme = "Colloid-Dark-Compact-Nord"; - gtkThemePkg = pkgs.colloid-gtk-theme.override { - sizeVariants = [ gtkThemeSize ]; - colorVariants = [ gtkThemeColor ]; - themeVariants = [ gtkThemeAccent ]; - tweaks = [ gtkThemeVariant ]; - }; - iconThemeColor = "dark"; # "" "light" "dark" - # iconThemeVariant = "default"; # "" "purple" "pink" "red" "orange" "yellow" "green" "teal" "grey" - iconThemeScheme = "nord"; # "" "nord" "dracula" "gruvbox" "everforest" "catppuccin" - iconTheme = "Colloid-${iconThemeScheme}-${iconThemeColor}"; - iconThemePkg = pkgs.colloid-icon-theme.override { schemeVariants = [ iconThemeScheme ]; }; -in { home.username = "matt"; home.homeDirectory = "/home/matt"; home.stateVersion = "23.11"; - programs.home-manager.enable = true; - - programs = { - fish.enable = false; - java.enable = true; - - zsh = { - enable = true; - enableCompletion = true; - autosuggestion.enable = true; - syntaxHighlighting.enable = true; - - shellAliases = { - ll = "ls -alh"; - update = "sudo nixos-rebuild switch"; - nas-update = "nixos-rebuild switch --use-remote-sudo --target-host admin@jallen-nas.local --build-host localhost --flake ~/nix-config/flake.nix#jallen-nas"; - nas-ssh = "ssh admin@jallen-nas.local"; - }; - - oh-my-zsh = { - enable = true; - plugins = [ "git" ]; - theme = "fishy"; - }; - }; - }; - - programs.git = { - enable = true; - userName = "mjallen18"; - userEmail = "matt.l.jallen@gmail.com"; - aliases = { - co = "checkout"; - ci = "commit"; - cia = "commit --amend"; - s = "status"; - st = "status"; - b = "branch"; - # p = "pull --rebase"; - pu = "push"; - }; - }; - - home.packages = with pkgs; [ - apple-cursor - colloid-icon-theme - colloid-gtk-theme - nixfmt-rfc-style - deadnix - papirus-icon-theme - gnomeExtensions.dash-to-dock - gnomeExtensions.arcmenu - gnomeExtensions.appindicator - gnomeExtensions.tiling-assistant - gnome-tweaks - iconThemePkg - gtkThemePkg - orca-slicer - vesktop - vscodium - ]; - - dconf = { - enable = true; - settings = { - "org/gnome/desktop/interface".clock-format = "12h"; - "org/gnome/desktop/interface".color-scheme = "prefer-dark"; - "org/gnome/desktop/interface".cursor-theme = "macOS"; - "org/gnome/desktop/interface".enable-hot-corners = false; - "org/gnome/desktop/interface".font-antialiasing = "grayscale"; - "org/gnome/desktop/interface".font-hinting = "slight"; - "org/gnome/desktop/interface".icon-theme = "Colloid-Nord-Dark"; - "org/gnome/desktop/interface".gtk-theme = "Colloid-Dark"; - "org/gnome/desktop/peripherals/mouse".accel-profile = "flat"; - "org/gnome/desktop/peripherals/touchpad".two-finger-scrolling-enabled = true; - "org/gnome/desktop/peripherals/touchpad".tap-to-click = true; - "org/gnome/mutter".experimental-features = [ - "scale-monitor-framebuffer" - "variable-refresh-rate" - ]; - "org/gnome/tweaks".show-extensions-notice = false; - "org/gnome/shell/extensions/user-theme".name = "Colloid-Dark"; - "org/gnome/shell".enabled-extensions = [ - "appindicatorsupport@rgcjonas.gmail.com" - "user-theme@gnome-shell-extensions.gcampax.github.com" - "dash-to-dock@micxgx.gmail.com" - "tiling-assistant@leleat-on-github" - ]; - "org/gtk/settings/file-chooser".clock-format = "12h"; - }; - }; - } diff --git a/hosts/mac-nixos/hyprland/config.nix b/hosts/mac-nixos/hyprland/config.nix deleted file mode 100755 index ba441bf..0000000 --- a/hosts/mac-nixos/hyprland/config.nix +++ /dev/null @@ -1,13 +0,0 @@ -let configDir = ./config; -in -{ - home.file = { - ".config/wallpapers".source = "${configDir}/wallpapers"; - ".config/kitty/macchiato.conf".source = "${configDir}/kitty/macchiato.conf"; - ".config/wlogout".source = "${configDir}/wlogout"; # - ".config/waybar/scripts".source = "${configDir}/waybar/scripts"; - ".config/btop/themes/catppuccin_macchiato.theme".source = "${configDir}/btop/themes/catppuccin_macchiato.theme"; - ".config/nwg-drawer".source = "${configDir}/nwg-drawer"; - ".config/nwg-panel".source = "${configDir}/nwg-panel"; - }; -} diff --git a/hosts/mac-nixos/hyprland/config/btop/default.nix b/hosts/mac-nixos/hyprland/config/btop/default.nix deleted file mode 100755 index 182baeb..0000000 --- a/hosts/mac-nixos/hyprland/config/btop/default.nix +++ /dev/null @@ -1,71 +0,0 @@ -{ - programs.btop = { - enable = true; - settings = { - color_theme = "/home/matt/.config/btop/themes/catppuccin_macchiato.theme"; - theme_background = true; - truecolor = true; - force_tty = false; - presets = "cpu:1:default,proc:0:default cpu:0:default,mem:0:default,net:0:default cpu:0:block,net:0:tty"; - vim_keys = true; - rounded_corners = true; - graph_symbol = "braille"; - graph_symbol_cpu = "default"; - graph_symbol_mem = "default"; - graph_symbol_net = "default"; - graph_symbol_proc = "default"; - shown_boxes = "cpu mem net proc"; - update_ms = 2000; - proc_sorting = "cpu lazy"; - proc_reversed = false; - proc_tree = false; - proc_colors = true; - proc_gradient = true; - proc_per_core = false; - proc_mem_bytes = true; - proc_cpu_graphs = true; - proc_info_smaps = false; - proc_left = false; - proc_filter_kernel = false; - cpu_graph_upper = "total"; - cpu_graph_lower = "total"; - cpu_invert_lower = true; - cpu_single_graph = false; - cpu_bottom = false; - show_uptime = true; - check_temp = true; - cpu_sensor = "Auto"; - show_coretemp = true; - cpu_core_map = ""; - temp_scale = "celsius"; - base_10_sizes = false; - show_cpu_freq = true; - clock_format = "%X"; - background_update = true; - custom_cpu_name = ""; - disks_filter = ""; - mem_graphs = true; - mem_below_net = false; - zfs_arc_cached = true; - show_swap = true; - swap_disk = true; - show_disks = true; - only_physical = true; - use_fstab = true; - zfs_hide_datasets = false; - disk_free_priv = false; - show_io_stat = true; - io_mode = false; - io_graph_combined = false; - io_graph_speeds = ""; - net_download = 100; - net_upload = 100; - net_auto = true; - net_sync = true; - net_iface = ""; - show_battery = true; - selected_battery = "Auto"; - log_level = "WARNING"; - }; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/btop/themes/catppuccin_macchiato.theme b/hosts/mac-nixos/hyprland/config/btop/themes/catppuccin_macchiato.theme deleted file mode 100755 index 7abd0bf..0000000 --- a/hosts/mac-nixos/hyprland/config/btop/themes/catppuccin_macchiato.theme +++ /dev/null @@ -1,42 +0,0 @@ -theme[main_bg]="#24273A" -theme[main_fg]="#CAD3F5" -theme[title]="#CAD3F5" -theme[hi_fg]="#8AADF4" -theme[selected_bg]="#494D64" -theme[selected_fg]="#8AADF4" -theme[inactive_fg]="#8087A2" -theme[graph_text]="#F4DBD6" -theme[meter_bg]="#494D64" -theme[proc_misc]="#F4DBD6" -theme[cpu_box]="#7DC4E4" -theme[mem_box]="#A6DA95" -theme[net_box]="#C6A0F6" -theme[proc_box]="#F0C6C6" -theme[div_line]="#6E738D" -theme[temp_start]="#EED49F" -theme[temp_mid]="#F5A97F" -theme[temp_end]="#ED8796" -theme[cpu_start]="#7DC4E4" -theme[cpu_mid]="#91D7E3" -theme[cpu_end]="#8BD5CA" -theme[free_start]="#8BD5CA" -theme[free_mid]="#8BD5CA" -theme[free_end]="#A6DA95" -theme[cached_start]="#F5BDE6" -theme[cached_mid]="#F5BDE6" -theme[cached_end]="#C6A0F6" -theme[available_start]="#F4DBD6" -theme[available_mid]="#F0C6C6" -theme[available_end]="#F0C6C6" -theme[used_start]="#F5A97F" -theme[used_mid]="#F5A97F" -theme[used_end]="#ED8796" -theme[download_start]="#B7BDF8" -theme[download_mid]="#B7BDF8" -theme[download_end]="#C6A0F6" -theme[upload_start]="#B7BDF8" -theme[upload_mid]="#B7BDF8" -theme[upload_end]="#C6A0F6" -theme[process_start]="#7DC4E4" -theme[process_mid]="#91D7E3" -theme[process_end]="#8BD5CA" diff --git a/hosts/mac-nixos/hyprland/config/hypr/default.nix b/hosts/mac-nixos/hyprland/config/hypr/default.nix deleted file mode 100755 index 17bf0b0..0000000 --- a/hosts/mac-nixos/hyprland/config/hypr/default.nix +++ /dev/null @@ -1,271 +0,0 @@ -{ - wayland.windowManager.hyprland = { - enable = true; - xwayland.enable = true; - systemd.enable = true; - - settings = { - "$mod" = "SUPER"; - - # Mouse - # mouse_[up|down] - scroll wheel - # middle_mouse - 274 - # thumb_up - 276 - # thumb_down - 275 - - # l -> locked, will also work when an input inhibitor (e.g. a lockscreen) is active. - # r -> release, will trigger on release of a key. - # e -> repeat, will repeat when held. - # n -> non-consuming, key/mouse events will be passed to the active window in addition to triggering the dispatcher. - # m -> mouse, see below. - # t -> transparent, cannot be shadowed by other binds. - # i -> ignore mods, will ignore modifiers. - # s -> separate, will arbitrarily combine keys between each mod/key, see [Keysym combos](#keysym-combos) above. - # d -> has description, will allow you to write a description for your bind. - # p -> bypasses the app's requests to inhibit keybinds. - - # https://wiki.hyprland.org/Configuring/Binds/ - # https://wiki.hyprland.org/Configuring/Binds/#mouse-buttons - - bind = [ - "$mod, Return, exec, kitty" - "$mod, Q, killactive, " - "$mod, mouse:274, killactive, " - "$mod, M, exec, wlogout --protocol layer-shell" - "$mod, E, exec, nautilus" - "$mod, V, togglefloating, " - "$mod, D, exec, nwg-drawer -fm nautilus -term kitty" - "$mod, P, pseudo, "# dwindle - "$mod, S, togglesplit, "# dwindle - "$mod SHIFT, Q, exec, hyprlock" - ", PRINT, exec, hyprshot -m region --clipboard-only" - "$mod,F,exec,hyprctl dispatch fullscreen active" - - # alt-tab between workspaces on active monitor - "ALT, Tab, workspace, m+1" - "ALT SHIFT, Tab, workspace, m-1" - - "$mod, h, movefocus, l" - "$mod, l, movefocus, r" - "$mod, k, movefocus, u" - "$mod, j, movefocus, d" - - "$mod, 1, workspace, 1" - "$mod, 2, workspace, 2" - "$mod, 3, workspace, 3" - "$mod, 4, workspace, 4" - "$mod, 5, workspace, 5" - "$mod, 6, workspace, 6" - "$mod, 7, workspace, 7" - "$mod, 8, workspace, 8" - "$mod, 9, workspace, 9" - "$mod, 0, workspace, 10" - - "$mod SHIFT, 1, movetoworkspace, 1" - "$mod SHIFT, 2, movetoworkspace, 2" - "$mod SHIFT, 3, movetoworkspace, 3" - "$mod SHIFT, 4, movetoworkspace, 4" - "$mod SHIFT, 5, movetoworkspace, 5" - "$mod SHIFT, 6, movetoworkspace, 6" - "$mod SHIFT, 7, movetoworkspace, 7" - "$mod SHIFT, 8, movetoworkspace, 8" - "$mod SHIFT, 9, movetoworkspace, 9" - "$mod SHIFT, 0, movetoworkspace, discord" - - "$mod CTRL, l, resizeactive, 10 0" - "$mod CTRL, h, resizeactive, -10 0" - "$mod CTRL, k, resizeactive, 0 -10" - "$mod CTRL, j, resizeactive, 0 10" - - "$mod SHIFT, l, movewindow, r" - "$mod SHIFT, h, movewindow, l" - "$mod SHIFT, k, movewindow, u" - "$mod SHIFT, j, movewindow, d" - - "$mod, b, exec, firefox" - ]; - - bindm = [ - # Move/resize windows with mod + LMB/RMB and dragging - "$mod, mouse:272, movewindow" - "$mod, mouse:273, resizewindow" - # middle mouse will grab a window, mod + middle mouse will close it - ", mouse:274, movewindow" - ]; - - bindel =[ - ", XF86AudioRaiseVolume, exec, wpctl set-volume -l 1.5 @DEFAULT_AUDIO_SINK@ 5%+" - ", XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-" - ]; - - bindl = [ - ", XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle" - ", XF86AudioPlay, exec, playerctl play-pause" - ", XF86AudioPrev, exec, playerctl previous" - ", XF86AudioNext, exec, playerctl next" - ]; - - monitor = [ - "DP-1,3840x2160@240.00000,0x0,1" - "DP-2,3840x2160@59.99700,3840x0,1" - ]; - - general = { - gaps_in = 5; - gaps_out = 10; - border_size = 1; - "col.active_border" = "rgb(8aadf4) rgb(24273A) rgb(24273A) rgb(8aadf4) 45deg"; - "col.inactive_border" = "rgb(24273A) rgb(24273A) rgb(24273A) rgb(24273A) 45deg"; - layout = "dwindle"; - allow_tearing = true; - }; - - decoration = { - rounding = 10; - blur = { - enabled = true; - size = 2; - passes = 2; - new_optimizations = true; - xray = false; - }; - drop_shadow = "yes"; - shadow_range = 4; - shadow_render_power = "3"; - "col.shadow" = "rgba(1a1a1aee)"; - }; - - animations = { - enabled = "yes"; - bezier = [ - "overshot, 0.05, 0.9, 0.1, 1.05" - "smoothOut, 0.36, 0, 0.66, -0.56" - "smoothIn, 0.25, 1, 0.5, 1" - ]; - animation = [ - "windows, 1, 5, overshot, slide" - "windowsOut, 1, 4, smoothOut, slide" - "windowsMove, 1, 4, default" - "border, 1, 10, default" - "fade, 1, 10, smoothIn" - "fadeDim, 1, 10, smoothIn" - "workspaces, 1, 6, default" - ]; - }; - - dwindle = { - pseudotile = "yes"; - preserve_split = "yes"; - }; - - gestures = { - workspace_swipe = "off"; - }; - - misc = { - force_default_wallpaper = 0; - }; - - workspace = [ - "name:firefox, monitor:DP-2, default:false, special, firefox" - "name:discord, monitor:DP-2, default:true, special, vesktop, spotify" - "name:steam, monitor:DP-2, default:false, special, steam" - ]; - - windowrule = [ - "float, file_progress" - "float, confirm" - "float, dialog" - "float, download" - "float, notification" - "float, error" - "float, splash" - "float, confirmreset" - "float, title:Open File" - "float, title:branchdialog" - "float, pavucontrol" - "move onscreen cursor 0% 0%, pavucontrol" - "float, file-roller" - "fullscreen, wlogout" - "float, title:wlogout" - "fullscreen, title:wlogout" - "idleinhibit stayfocused, mpv" - "fullscreen, title:BBar" - "fullscreen, title:Remote Desktop Connection" - "norounding, class:Remote Desktop Connection" - "noshadow, class:Remote Desktop Connection" - "immediate, class:Remote Desktop Connection" - "syncfullscreen, class:Remote Desktop Connection" - "allowsinput, class:Remote Desktop Connection" - "noanim, class:Remote Desktop Connection" - "noblur, class:Remote Desktop Connection" - "noborder, class:Remote Desktop Connection" - "nodim, class:Remote Desktop Connection" - "nomaxsize, class:Remote Desktop Connection" - "minsize 3840 2160, class:Remote Desktop Connection" - ]; - windowrulev2 = [ - "float, class:Vmware-view,title:VMware Horizon Client" - "size 3840 2160, class:Remote Desktop Connection" - # "float, class:Remote Desktop Connection,title:BBar" - # "float, class:Remote Desktop Connection,title:Remote Desktop Connection" - "float, class:Credential Manager UI Host,title:Windows Security" - "float, title:^(Media viewer)$" - # Picture in picture windows - # "float, class:pavucontrol,title:pavucontrol" # ????? - "float, title:^(Picture-in-Picture)$" - "pin, title:^(Picture-in-Picture)$" - "float, class:^(vesktop)$,title:^(Discord Popout)$" - "pin, class:^(vesktop)$,title:^(Discord Popout)$" - "float, class:^(steam)$,title:^(Friends List)$" - # Workspace assign - # "workspace: 1, class:^(kitty)$" - # "workspace: name:discord, class:^(firefox)$" - "workspace: name:discord, class:^(vesktop)$" - - # Steam - "float, class:^([Ss]team)$, title:^((?![Ss]team).*)$" - "workspace name:steam silent, class:^([Ss]team)$, title:^([Ss]team)$" - "tile, class:^([Ss]team)$, title:^([Ss]team)$" - - # Code - # "pin, class:^(code)$,title:^(Save As)$" - "float, class:^(code)$,title:^(Save As)$" - "float, class:^(xdg-desktop-portal-gtk)$,title:^(Open Workspace from File)$" - - # Game Tearing??? https://wiki.hyprland.org/Configuring/Tearing/ - "immediate, class:gamescope" - ]; - - input = { - kb_layout = "us"; - - kb_variant = ""; - kb_model = ""; - kb_options = ""; - kb_rules = ""; - - numlock_by_default = true; - - follow_mouse = 1; - - touchpad = { - natural_scroll = "no"; - }; - - sensitivity = 0; # -1.0 - 1.0, 0 means no modification. - }; - }; - - extraConfig = '' - exec-once = dbus-update-activation-environment --systemd --all - exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP - exec-once = /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 - exec-once = nwg-look -a - exec-once = [silent] firefox - exec-once = [silent] vesktop - exec-once = [silent] spotify - exec-once = [silent] steam - ''; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/kitty/default.nix b/hosts/mac-nixos/hyprland/config/kitty/default.nix deleted file mode 100755 index 1917799..0000000 --- a/hosts/mac-nixos/hyprland/config/kitty/default.nix +++ /dev/null @@ -1,26 +0,0 @@ -{ pkgs, ... }: -{ - programs.kitty = { - enable = true; - shellIntegration.enableZshIntegration = true; - - font = { - name = "nerd-fonts-jetbrains-mono"; - package = pkgs.nerd-fonts.jetbrains-mono; - size = 12; - }; - - settings = { - include = "~/.config/kitty/macchiato.conf"; - bold_font = "auto"; - italic_font = "auto"; - bold_italic_font = "auto"; - mouse_hide_wait = "2.0"; - cursor_shape = "block"; - url_color = "#0087bd"; - url_style = "dotted"; - confirm_os_window_close = "0"; - background_opacity = "0.8"; - }; - }; -} diff --git a/hosts/mac-nixos/hyprland/config/kitty/macchiato.conf b/hosts/mac-nixos/hyprland/config/kitty/macchiato.conf deleted file mode 100755 index d50dbe6..0000000 --- a/hosts/mac-nixos/hyprland/config/kitty/macchiato.conf +++ /dev/null @@ -1,80 +0,0 @@ -# vim:ft=kitty - -## name: Catppuccin Kitty Macchiato -## author: Catppuccin Org -## license: MIT -## upstream: https://github.com/catppuccin/kitty/blob/main/themes/macchiato.conf -## blurb: Soothing pastel theme for the high-spirited! - - - -# The basic colors -foreground #CAD3F5 -background #24273A -selection_foreground #24273A -selection_background #F4DBD6 - -# Cursor colors -cursor #F4DBD6 -cursor_text_color #24273A - -# URL underline color when hovering with mouse -url_color #F4DBD6 - -# Kitty window border colors -active_border_color #B7BDF8 -inactive_border_color #6E738D -bell_border_color #EED49F - -# OS Window titlebar colors -wayland_titlebar_color #24273A -macos_titlebar_color #24273A - -# Tab bar colors -active_tab_foreground #181926 -active_tab_background #C6A0F6 -inactive_tab_foreground #CAD3F5 -inactive_tab_background #1E2030 -tab_bar_background #181926 - -# Colors for marks (marked text in the terminal) -mark1_foreground #24273A -mark1_background #B7BDF8 -mark2_foreground #24273A -mark2_background #C6A0F6 -mark3_foreground #24273A -mark3_background #7DC4E4 - -# The 16 terminal colors - -# black -color0 #494D64 -color8 #5B6078 - -# red -color1 #ED8796 -color9 #ED8796 - -# green -color2 #A6DA95 -color10 #A6DA95 - -# yellow -color3 #EED49F -color11 #EED49F - -# blue -color4 #8AADF4 -color12 #8AADF4 - -# magenta -color5 #F5BDE6 -color13 #F5BDE6 - -# cyan -color6 #8BD5CA -color14 #8BD5CA - -# white -color7 #B8C0E0 -color15 #A5ADCB diff --git a/hosts/mac-nixos/hyprland/config/mako/default.nix b/hosts/mac-nixos/hyprland/config/mako/default.nix deleted file mode 100755 index 1c91120..0000000 --- a/hosts/mac-nixos/hyprland/config/mako/default.nix +++ /dev/null @@ -1,21 +0,0 @@ -{ - services.mako = { - enable = true; - font = "monospace 12"; - icons = false; - width = 500; - height = 110; - layer = "overlay"; - borderRadius = 15; - borderSize = 2; - maxIconSize = 64; - defaultTimeout = 5000; - sort = "-time"; - ignoreTimeout = true; - - backgroundColor = "#24273a"; - textColor = "#cad3f5"; - borderColor = "#8aadf4"; - progressColor = "over #363a4f"; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/nwg-drawer/drawer.css b/hosts/mac-nixos/hyprland/config/nwg-drawer/drawer.css deleted file mode 100755 index a893075..0000000 --- a/hosts/mac-nixos/hyprland/config/nwg-drawer/drawer.css +++ /dev/null @@ -1,34 +0,0 @@ -window { - background-color: rgba (36, 47, 79, 0.95); - color: #eeeeee -} - -/* search entry */ -entry { - background-color: rgba (0, 0, 0, 0.2) -} - -button, image { - background: none; - border: none -} - -button:hover { - background-color: rgba (255, 255, 255, 0.1) -} - -/* in case you wanted to give category buttons a different look */ -#category-button { - margin: 0 10px 0 10px -} - -#pinned-box { - padding-bottom: 5px; - border-bottom: 1px dotted gray -} - -#files-box { - padding: 5px; - border: 1px dotted gray; - border-radius: 15px -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/nwg-panel/excluded-dirs b/hosts/mac-nixos/hyprland/config/nwg-panel/excluded-dirs deleted file mode 100755 index e69de29..0000000 diff --git a/hosts/mac-nixos/hyprland/config/nwg-panel/preferred-apps.json b/hosts/mac-nixos/hyprland/config/nwg-panel/preferred-apps.json deleted file mode 100755 index 224a65e..0000000 --- a/hosts/mac-nixos/hyprland/config/nwg-panel/preferred-apps.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "\\.pdf$": "firefox", - "\\.svg$": "inkscape", - "\\.(jpg|png|tiff|gif)$": "swayimg", - "\\.(mp3|ogg|flac|wav|wma)$": "audacious", - "\\.(avi|mp4|mkv|mov|wav)$": "mpv", - "\\.(doc|docx|xls|xlsx)$": "libreoffice" -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/wallpapers/wall.png b/hosts/mac-nixos/hyprland/config/wallpapers/wall.png deleted file mode 100755 index a7f07a9..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wallpapers/wall.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/waybar/default.nix b/hosts/mac-nixos/hyprland/config/waybar/default.nix deleted file mode 100755 index d5f5308..0000000 --- a/hosts/mac-nixos/hyprland/config/waybar/default.nix +++ /dev/null @@ -1,302 +0,0 @@ -{ - # https://github.com/Alexays/Waybar/wiki/Module:-Hyprland - - programs.waybar = { - enable = true; - systemd.enable = true; - settings = { - mainBar = { - layer = "bottom"; - position = "top"; - mod = "dock"; - exclusive = true; - passthrough = false; - gtk-layer-shell = true; - height = 0; - modules-left = [ - "hyprland/workspaces" - ]; - - modules-center = [ - "hyprland/window" - ]; - - modules-right = [ - "tray" - "custom/updates" - "keyboard-state#capslock" - "keyboard-state#numlock" - "pulseaudio" - "pulseaudio#microphone" - "network" - "clock" - "custom/weather" - ]; - - "hyprland/window" = { - format = {}; - }; - - "hyprland/workspaces" = { - disable-scroll = true; - all-outputs = true; - on-click = "activate"; - persistent_workspaces = { - "1" = []; - }; - }; - - "custom/weather" = { - tooltip = true; - format = {}; - interval = 30; - exec = "sudo waybar-weather"; - return-type = "json"; - }; - - "custom/updates" = { - tooltip = true; - format = {}; - interval = 60; - exec = "sudo waybar-updates"; - return-type = "json"; - }; - - tray = { - icon-size = 16; - spacing = 10; - }; - - clock = { - format = "{:%I:%M %p}"; - tooltip-format = "{:%Y %B}\n{calendar}"; - }; - - pulseaudio = { - format = "{icon} {volume}%"; - tooltip = false; - format-muted = " Muted"; - on-click = "pamixer -t"; - on-click-right = "pavucontrol -t 1"; - on-scroll-up = "pamixer -i 5"; - on-scroll-down = "pamixer -d 5"; - scroll-step = 5; - format-icons = { - headphone = ""; - hands-free = ""; - headset = ""; - phone = ""; - portable = ""; - car = ""; - default = ["" "" ""]; - }; - }; - - "pulseaudio#microphone" = { - format = "{format_source}"; - format-source = "🎙{volume}%"; - format-source-muted = "🎙Muted"; - on-click = "pamixer --default-source -t"; - on-click-right = "pavucontrol -t 2"; - on-scroll-up = "pamixer --default-source -i 5"; - on-scroll-down = "pamixer --default-source -d 5"; - scroll-step = 5; - }; - - network = { - interface = "wlp9s0"; - format = "{ifname}"; - format-wifi = "{essid} ({signalStrength}%) "; - format-ethernet = "{ifname} "; - format-disconnected = ""; # An empty format will hide the module. - tooltip-format = "{ifname}"; - tooltip-format-wifi = "{essid} ({signalStrength}%) "; - tooltip-format-ethernet = "{ifname} "; - tooltip-format-disconnected = "Disconnected"; - max-length = 50; - }; - - "keyboard-state#capslock" = { - capslock = true; - format = "{name} {icon}"; - format-icons = { - locked = ""; - unlocked = ""; - }; - }; - - "keyboard-state#numlock" = { - numlock = true; - format = "{name} {icon}"; - format-icons = { - locked = ""; - unlocked = ""; - }; - }; - }; - }; - - # https://catppuccin.com/palette - style = '' - * { - border: none; - border-radius: 0; - font-family: - Jetbrains Mono Nerd Font, - monospace; - font-weight: bold; - font-size: 14px; - min-height: 0; - } - - window#waybar { - background: rgba(21, 18, 27, 0); - color: #cdd6f4; - } - - tooltip { - background: #1e1e2e; - border-radius: 10px; - border-width: 2px; - border-style: solid; - border-color: #11111b; - } - - #workspaces button { - padding: 5px; - color: #313244; - margin-right: 5px; - } - - #workspaces button.active { - color: #a6adc8; - } - - #workspaces button.focused { - color: #a6adc8; - background: #eba0ac; - border-radius: 10px; - } - - #workspaces button.urgent { - color: #11111b; - background: #a6e3a1; - border-radius: 10px; - } - - #workspaces button:hover { - background: #11111b; - color: #cdd6f4; - border-radius: 10px; - } - - #custom-updates, - #custom-caffeine, - #custom-weather, - #window, - #clock, - #battery, - #pulseaudio, - #network, - #workspaces, - #keyboard-state.numlock, - #keyboard-state.capslock, - #tray, - #backlight { - background: #1e1e2e; - padding: 0px 10px; - margin: 3px 0px; - margin-top: 10px; - border: 1px solid #181825; - } - - #tray { - border-radius: 10px; - margin-right: 10px; - } - - #workspaces { - background: #1e1e2e; - border-radius: 10px; - margin-left: 10px; - padding-right: 0px; - padding-left: 5px; - } - - #custom-caffeine { - color: #89dceb; - border-radius: 10px 0px 0px 10px; - border-right: 0px; - margin-left: 10px; - } - - #custom-updates { - color: #f5c2e7; - border-radius: 10px 0px 0px 10px; - border-left: 0px; - border-right: 0px; - } - - #window { - border-radius: 10px; - margin-left: 60px; - margin-right: 60px; - } - - #clock { - color: #f5a97f; - border-radius: 10px 0px 0px 10px; - margin-left: 5px; - border-right: 0px; - } - - #keyboard-state.capslock { - color: #91d7e3; - border-left: 0px; - border-right: 0px; - } - - #keyboard-state.numlock { - color: #7dc4e4; - border-left: 0px; - border-right: 0px; - } - - #network { - color: #eed49f; - border-left: 0px; - border-right: 0px; - border-radius: 10px 10px 10px 10px; - margin-left: 5px; - padding-right: 15px; - } - - #pulseaudio { - color: #8aadf4; - border-left: 0px; - border-right: 0px; - } - - #pulseaudio.microphone { - color: #c6a0f6; - border-radius: 0px 10px 10px 0px; - border-left: 0px; - border-right: 0px; - padding-top: 5px; - } - - #battery { - color: #a6e3a1; - border-radius: 0 10px 10px 0; - margin-right: 10px; - border-left: 0px; - } - - #custom-weather { - border-radius: 0px 10px 10px 0px; - border-right: 0px; - margin-left: 0px; - } - ''; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-updates.py b/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-updates.py deleted file mode 100755 index 1f93357..0000000 --- a/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-updates.py +++ /dev/null @@ -1,85 +0,0 @@ -#!/usr/bin/env python - -import os -import json -import subprocess -import re -from datetime import datetime -import time - -tmp_path = '/tmp/waybar-scripts/updates' -json_cache = tmp_path + "/data.json" -git_repo = 'git@github.com:mjallen18/nix-config.git' - -def cache_json(data): - with open(json_cache, mode="w") as cache: - json.dump(data, cache) - -def create_folders(): - if not os.path.exists(tmp_path): - os.makedirs(tmp_path) - os.chdir(tmp_path) - -def clone_repo(): - reset_repo() - if os.path.exists(tmp_path) and len(os.listdir(tmp_path)) == 0: - subprocess.run(["git", "clone", git_repo, tmp_path]) - -def check_for_flake_updates(): - return subprocess.run(["sudo", "nix", "flake", "update", "-I", tmp_path, tmp_path], capture_output=True, text=True) - -def reset_repo(): - if os.path.exists(tmp_path) and not len(os.listdir(tmp_path)) == 0: - subprocess.run(["git", "reset", "--hard"]) - subprocess.run(["git", "pull"]) - -def parse_output(output): - updates_dict = {} - updates = re.findall(r"(• Updated input '(.+)':((\n|\r|\n)(.+\((\d\d\d\d-\d\d-\d\d\)))){2})", output) - for update in updates: - input = re.findall(r"'(.+)':", update[0])[0].strip() - dates = re.findall(r"(\d{4}-\d{2}-\d{2})", update[0]) - updates_dict[input] = dates - return updates_dict - -def check(): - data = {} - # print("create folders") - create_folders() - # print("clone repo") - clone_repo() - # print("checking for updates") - updates = check_for_flake_updates() - updates_dict = parse_output(updates.stderr) - - data["text"] = (str(len(updates_dict.keys()))) - if len(updates_dict.keys()) <= 0: - data["tooltip"] = ("flake inputs up to date") - else: - data["tooltip"] = ("flake input updates:\n\n") - - for input in updates_dict.keys(): - data["tooltip"] += "{}\n".format(input) - data["tooltip"] += "Old Ref: {0} → {1}\n\n".format(updates_dict[input][0].strip(), updates_dict[input][1].strip()) - - cache_json(data) - - print(json.dumps(data)) - -def read_cache(): - with open(json_cache, mode="r") as cache: - print(json.dumps(json.load(cache))) - -def main(): - now = int(datetime.now().strftime("%H")) - if os.path.exists(json_cache): - mtime = int(time.localtime(os.stat(json_cache).st_ctime).tm_hour) - else: - mtime = now + 1 - - if (now % 2 == 0 and mtime < now) or not os.path.exists(json_cache): - check() - else: - read_cache() - -main() diff --git a/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-wttr.py b/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-wttr.py deleted file mode 100755 index a6a87a1..0000000 --- a/hosts/mac-nixos/hyprland/config/waybar/scripts/waybar-wttr.py +++ /dev/null @@ -1,137 +0,0 @@ -#!/usr/bin/env python - -import json -from datetime import datetime - -import requests - -WEATHER_CODES = { - "113": "☀️ ", - "116": "⛅ ", - "119": "☁️ ", - "122": "☁️ ", - "143": "☁️ ", - "176": "🌧️", - "179": "🌧️", - "182": "🌧️", - "185": "🌧️", - "200": "⛈️ ", - "227": "🌨️", - "230": "🌨️", - "248": "☁️ ", - "260": "☁️ ", - "263": "🌧️", - "266": "🌧️", - "281": "🌧️", - "284": "🌧️", - "293": "🌧️", - "296": "🌧️", - "299": "🌧️", - "302": "🌧️", - "305": "🌧️", - "308": "🌧️", - "311": "🌧️", - "314": "🌧️", - "317": "🌧️", - "320": "🌨️", - "323": "🌨️", - "326": "🌨️", - "329": "❄️ ", - "332": "❄️ ", - "335": "❄️ ", - "338": "❄️ ", - "350": "🌧️", - "353": "🌧️", - "356": "🌧️", - "359": "🌧️", - "362": "🌧️", - "365": "🌧️", - "368": "🌧️", - "371": "❄️", - "374": "🌨️", - "377": "🌨️", - "386": "🌨️", - "389": "🌨️", - "392": "🌧️", - "395": "❄️ ", -} - -data = {} - - -weather = requests.get("https://wttr.in/?format=j1").json() - - -def format_time(time): - return datetime.strptime(format_24_time(time), "%H").strftime("%I %p") - -def format_24_time(time): - return time.replace("00", "").zfill(2) - - -def format_temp(temp): - return (hour["FeelsLikeF"] + "°").ljust(3) - - -def format_chances(hour): - chances = { - "chanceoffog": "Fog", - "chanceoffrost": "Frost", - "chanceofovercast": "Overcast", - "chanceofrain": "Rain", - "chanceofsnow": "Snow", - "chanceofsunshine": "Sunshine", - "chanceofthunder": "Thunder", - "chanceofwindy": "Wind", - } - - conditions = [] - for event in chances.keys(): - if int(hour[event]) > 0: - conditions.append(chances[event] + " " + hour[event] + "%") - return ", ".join(conditions) - - -tempint = int(weather["current_condition"][0]["FeelsLikeF"]) -extrachar = "" -if tempint > 0 and tempint < 10: - extrachar = "+" - - -data["text"] = ( - " " - + WEATHER_CODES[weather["current_condition"][0]["weatherCode"]] - + " " - + extrachar - + weather["current_condition"][0]["FeelsLikeF"] - + "°" -) - -data["tooltip"] = ( - f"{weather['current_condition'][0]['weatherDesc'][0]['value']} {weather['current_condition'][0]['temp_F']}°\n" -) -data["tooltip"] += f"Feels like: {weather['current_condition'][0]['FeelsLikeF']}°\n" -data["tooltip"] += f"Wind: {weather['current_condition'][0]['windspeedMiles']}mph\n" -data["tooltip"] += f"Humidity: {weather['current_condition'][0]['humidity']}%\n" -for i, day in enumerate(weather["weather"]): - data["tooltip"] += f"\n" - if i == 0: - data["tooltip"] += "Today, " - if i == 1: - data["tooltip"] += "Tomorrow, " - date = datetime.strptime(day['date'], "%Y-%m-%d").strftime("%a %b %d %Y") - data["tooltip"] += f"{date}\n" - data["tooltip"] += f"⬆️ {day['maxtempF']}° ⬇️ {day['mintempF']}° " - data[ - "tooltip" - ] += f"☀️ {day['astronomy'][0]['sunrise']} 🌕 {day['astronomy'][0]['sunset']}\n" - for hour in day["hourly"]: - if i == 0: - if int(format_24_time(hour["time"])) < datetime.now().hour - 2: - continue - data[ - "tooltip" - ] += f"{format_time(hour['time'])} {WEATHER_CODES[hour['weatherCode']]} {format_temp(hour['FeelsLikeF'])} {hour['weatherDesc'][0]['value']}, {format_chances(hour)}\n" - - -print(json.dumps(data)) diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/hibernate.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/hibernate.png deleted file mode 100755 index 1aa6730..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/hibernate.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/lock.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/lock.png deleted file mode 100755 index 2fdf2de..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/lock.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/logout.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/logout.png deleted file mode 100755 index c398d22..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/logout.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/reboot.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/reboot.png deleted file mode 100755 index 6db3aaa..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/reboot.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/shutdown.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/shutdown.png deleted file mode 100755 index 3025cd0..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/shutdown.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/icons/suspend.png b/hosts/mac-nixos/hyprland/config/wlogout/icons/suspend.png deleted file mode 100755 index 124a58e..0000000 Binary files a/hosts/mac-nixos/hyprland/config/wlogout/icons/suspend.png and /dev/null differ diff --git a/hosts/mac-nixos/hyprland/config/wlogout/layout b/hosts/mac-nixos/hyprland/config/wlogout/layout deleted file mode 100755 index 6e546a1..0000000 --- a/hosts/mac-nixos/hyprland/config/wlogout/layout +++ /dev/null @@ -1,36 +0,0 @@ -{ - "label" : "lock", - "action" : "swaylock", - "text" : "Lock", - "keybind" : "l" -} -{ - "label" : "hibernate", - "action" : "systemctl hibernate", - "text" : "Hibernate", - "keybind" : "h" -} -{ - "label" : "logout", - "action" : "sleep 1; hyprctl dispatch exit", - "text" : "Logout", - "keybind" : "e" -} -{ - "label" : "shutdown", - "action" : "systemctl poweroff", - "text" : "Shutdown", - "keybind" : "s" -} -{ - "label" : "suspend", - "action" : "systemctl suspend", - "text" : "Suspend", - "keybind" : "u" -} -{ - "label" : "reboot", - "action" : "systemctl reboot", - "text" : "Reboot", - "keybind" : "r" -} diff --git a/hosts/mac-nixos/hyprland/config/wlogout/style.css b/hosts/mac-nixos/hyprland/config/wlogout/style.css deleted file mode 100755 index 5ba48fe..0000000 --- a/hosts/mac-nixos/hyprland/config/wlogout/style.css +++ /dev/null @@ -1,50 +0,0 @@ -* { - background-image: none; -} - -window { - background-color: rgba(36, 39, 58, 0.9); -} - -button { - margin: 8px; - color: #cad3f5; - background-color: #363a4f; - border-style: solid; - border-width: 2px; - background-repeat: no-repeat; - background-position: center; - background-size: 25%; -} - -button:active, -button:focus, -button:hover { - color: #8bd5ca; - background-color: #24273a; - outline-style: none; -} - -#lock { - background-image: image(url("icons/lock.png")); -} - -#logout { - background-image: image(url("icons/logout.png")); -} - -#suspend { - background-image: image(url("icons/suspend.png")); -} - -#hibernate { - background-image: image(url("icons/hibernate.png")); -} - -#shutdown { - background-image: image(url("icons/shutdown.png")); -} - -#reboot { - background-image: image(url("icons/reboot.png")); -} diff --git a/hosts/mac-nixos/hyprland/config/wofi/default.nix b/hosts/mac-nixos/hyprland/config/wofi/default.nix deleted file mode 100755 index 08abc1b..0000000 --- a/hosts/mac-nixos/hyprland/config/wofi/default.nix +++ /dev/null @@ -1,145 +0,0 @@ -{ - programs.wofi = { - enable = false; - style = '' - @define-color rosewater #f4dbd6; - @define-color rosewater-rgb rgb(244, 219, 214); - @define-color flamingo #f0c6c6; - @define-color flamingo-rgb rgb(240, 198, 198); - @define-color pink #f5bde6; - @define-color pink-rgb rgb(245, 189, 230); - @define-color mauve #c6a0f6; - @define-color mauve-rgb rgb(198, 160, 246); - @define-color red #ed8796; - @define-color red-rgb rgb(237, 135, 150); - @define-color maroon #ee99a0; - @define-color maroon-rgb rgb(238, 153, 160); - @define-color peach #f5a97f; - @define-color peach-rgb rgb(245, 169, 127); - @define-color yellow #eed49f; - @define-color yellow-rgb rgb(238, 212, 159); - @define-color green #a6da95; - @define-color green-rgb rgb(166, 218, 149); - @define-color teal #8bd5ca; - @define-color teal-rgb rgb(139, 213, 202); - @define-color sky #91d7e3; - @define-color sky-rgb rgb(145, 215, 227); - @define-color sapphire #7dc4e4; - @define-color sapphire-rgb rgb(125, 196, 228); - @define-color blue #8aadf4; - @define-color blue-rgb rgb(138, 173, 244); - @define-color lavender #b7bdf8; - @define-color lavender-rgb rgb(183, 189, 248); - @define-color text #cad3f5; - @define-color text-rgb rgb(202, 211, 245); - @define-color subtext1 #b8c0e0; - @define-color subtext1-rgb rgb(184, 192, 224); - @define-color subtext0 #a5adcb; - @define-color subtext0-rgb rgb(165, 173, 203); - @define-color overlay2 #939ab7; - @define-color overlay2-rgb rgb(147, 154, 183); - @define-color overlay1 #8087a2; - @define-color overlay1-rgb rgb(128, 135, 162); - @define-color overlay0 #6e738d; - @define-color overlay0-rgb rgb(110, 115, 141); - @define-color surface2 #5b6078; - @define-color surface2-rgb rgb(91, 96, 120); - @define-color surface1 #494d64; - @define-color surface1-rgb rgb(73, 77, 100); - @define-color surface0 #363a4f; - @define-color surface0-rgb rgb(54, 58, 79); - @define-color base #24273a; - @define-color base-rgb rgb(36, 39, 58); - @define-color mantle #1e2030; - @define-color mantle-rgb rgb(30, 32, 48); - @define-color crust #181926; - @define-color crust-rgb rgb(24, 25, 38); - - * { - font-family: "Inconsolata Nerd Font", monospace; - font-size: 14px; - } - - /* Window */ - window { - margin: 0px; - padding: 10px; - border: 0.16em solid @lavender; - border-radius: 0.1em; - background-color: @base; - } - - /* Inner Box */ - #inner-box { - margin: 5px; - padding: 10px; - border: none; - background-color: @base; - } - - /* Outer Box */ - #outer-box { - margin: 5px; - padding: 10px; - border: none; - background-color: @base; - } - - /* Scroll */ - #scroll { - margin: 0px; - padding: 10px; - border: none; - background-color: @base; - } - - /* Input */ - #input { - margin: 5px 20px; - padding: 10px; - border: none; - border-radius: 0.1em; - color: @text; - background-color: @base; - } - - #input image { - border: none; - color: @red; - } - - #input * { - outline: 4px solid @red!important; - } - - /* Text */ - #text { - margin: 5px; - border: none; - color: @text; - } - - #entry { - background-color: @base; - } - - #entry arrow { - border: none; - color: @lavender; - } - - /* Selected Entry */ - #entry:selected { - border: 0.11em solid @lavender; - } - - #entry:selected #text { - color: @mauve; - } - - #entry:drop(active) { - background-color: @lavender!important; - } - ''; - }; -} \ No newline at end of file diff --git a/hosts/mac-nixos/hyprland/default.nix b/hosts/mac-nixos/hyprland/default.nix deleted file mode 100755 index 493750d..0000000 --- a/hosts/mac-nixos/hyprland/default.nix +++ /dev/null @@ -1,102 +0,0 @@ -{ pkgs, ... }: -let - sddmTheme = "catppuccin-mocha"; -in -{ - specialisation.hyprland.configuration = { - imports = [ - ./environment.nix - ]; - - home-manager.users.matt = import ./home.nix; - - services = { - displayManager.sddm.enable = true; - displayManager.sddm.package = pkgs.kdePackages.sddm; - displayManager.sddm.theme = sddmTheme; - displayManager.defaultSession = "hyprland"; - # disable plasma - desktopManager.plasma6.enable = false; - - dbus.enable = true; - - ddccontrol.enable = true; - }; - - programs.hyprland = { - enable = true; - xwayland.enable = true; - portalPackage = pkgs.xdg-desktop-portal-hyprland; - }; - - systemd = { - user.services.polkit-gnome-authentication-agent-1 = { - description = "polkit-gnome-authentication-agent-1"; - wantedBy = [ "graphical-session.target" ]; - wants = [ "graphical-session.target" ]; - after = [ "graphical-session.target" ]; - serviceConfig = { - Type = "simple"; - ExecStart = "${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"; - Restart = "on-failure"; - RestartSec = 1; - TimeoutStopSec = 10; - }; - }; - extraConfig = '' - DefaultTimeoutStopSec=10s - ''; - }; - - security = { - polkit.enable = true; - - # configure sudo - sudo.extraRules = [ - { - commands = [ - { - command = "/run/current-system/sw/bin/waybar-weather"; - options = [ "NOPASSWD" ]; - } - { - command = "/run/current-system/sw/bin/waybar-updates"; - options = [ "NOPASSWD" ]; - } - ]; - groups = [ "wheel" ]; - } - ]; - }; - - xdg.portal = { - enable = true; - wlr.enable = false; - xdgOpenUsePortal = false; - extraPortals = [ - pkgs.xdg-desktop-portal-hyprland - pkgs.xdg-desktop-portal-gtk - ]; - }; - - fonts.packages = with pkgs; [ - noto-fonts - noto-fonts-color-emoji - meslo-lgs-nf - ] ++ builtins.filter lib.attrsets.isDerivation (builtins.attrValues pkgs.nerd-fonts); - - fonts.fontconfig.defaultFonts = { - emoji = [ - "Noto Color Emoji" - ]; - }; - - nixpkgs.overlays = [ - (self: super: { - waybar = super.waybar.overrideAttrs (oldAttrs: { - mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ]; - }); - }) - ]; - }; -} diff --git a/hosts/mac-nixos/hyprland/environment.nix b/hosts/mac-nixos/hyprland/environment.nix deleted file mode 100755 index e889243..0000000 --- a/hosts/mac-nixos/hyprland/environment.nix +++ /dev/null @@ -1,53 +0,0 @@ -{ pkgs, ... }: -let - - waybarWeatherScript = pkgs.writeScriptBin "waybar-weather" '' - #!/usr/bin/env nix-shell - #! nix-shell -i bash --packages python3 python3Packages.requests - python /home/matt/.config/waybar/scripts/waybar-wttr.py - ''; - - waybarUpdatesScript = pkgs.writeScriptBin "waybar-updates" '' - /home/matt/.config/waybar/scripts/waybar-updates.py - ''; -in -{ - environment.systemPackages = with pkgs; [ - ddcutil - dunst - glib - gnome-disk-utility - gsettings-desktop-schemas - hyprland - hyprshot - libnotify - mako - meson - nautilus - networkmanagerapplet - nwg-drawer - nwg-look - pamixer - papirus-folders - pavucontrol - playerctl - polkit - polkit_gnome - qt5.qtwayland - qt6.qtwayland - rofi-wayland - waybar - waybarUpdatesScript - waybarWeatherScript - wayland-protocols - wayland-utils - wev - wl-clipboard - wlogout - wlroots - xdg-desktop-portal-hyprland - xdg-desktop-portal-gtk - xdg-desktop-portal-wlr - xwayland - ]; -} diff --git a/hosts/mac-nixos/hyprland/home.nix b/hosts/mac-nixos/hyprland/home.nix deleted file mode 100755 index 1fee0d4..0000000 --- a/hosts/mac-nixos/hyprland/home.nix +++ /dev/null @@ -1,181 +0,0 @@ -{ pkgs, ... }: -let - wallpaper = "/home/matt/.config/wallpapers/wall.png"; - cursorTheme = "macOS-Monterey"; - cursorThemePkg = pkgs.apple-cursor; - cursorSize = 24; - gtkThemeSize = "compact"; - gtkThemeAccent = "blue"; - gtkThemeVariant = "macchiato"; - gtkTheme = "catppuccin-${gtkThemeVariant}-${gtkThemeAccent}-${gtkThemeSize}"; - gtkThemePkg = pkgs.catppuccin-gtk.override { - size = gtkThemeSize; - accents = [ gtkThemeAccent ]; - variant = gtkThemeVariant; - }; - iconTheme = "Colloid-dark"; # Colloid, Colloid-light, Colloid-dark - iconThemePkg = pkgs.colloid-icon-theme; -in -{ - imports = [ - ./config.nix - ./config/btop - ./config/hypr - ./config/kitty - ./config/mako - ./config/waybar - ./config/wofi - ]; - - services = { - hyprpaper = { - enable = true; - settings = { - preload = [ wallpaper ]; - wallpaper = [ - "DP-1, ${wallpaper}" - "DP-2, ${wallpaper}" - ]; - splash = false; - }; - }; - - hypridle = { - enable = true; - settings = { - general = { - before_sleep_cmd = "loginctl lock-session"; # lock before suspend. - after_sleep_cmd = "hyprctl dispatch dpms on"; # to avoid having to press a key twice to turn on the display. - ignore_dbus_inhibit = false; - lock_cmd = "pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances. - }; - listener = [ - # { - # timeout = 300; # 5min - # on-timeout = "brightnessctl -s set 10"; # set monitor backlight to minimum, avoid 0 on OLED monitor. - # on-resume = "brightnessctl -r"; # monitor backlight restore. - # } - { - timeout = 900; # 15 min - on-timeout = "loginctl lock-session"; # lock screen when timeout has passed - } - { - timeout = 930; # 15.5 min - on-timeout = "hyprctl dispatch dpms off"; # screen off when timeout has passed - on-resume = "hyprctl dispatch dpms on"; # screen on when activity is detected after timeout has fired. - } - { - timeout = 3600; # 1hr - on-timeout = "systemctl suspend"; # suspend pc - } - ]; - }; - }; - }; - - programs.hyprlock = { - enable = true; - settings = { - background = [ - { - monitor = ""; - path = wallpaper; # supports png, jpg, webp (no animations, though) - color = "rgba(25, 20, 20, 1.0)"; - - # all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations - blur_passes = "3"; # 0 disables blurring - blur_size = "7"; - noise = "0.0117"; - contrast = "0.8916"; - brightness = "0.8172"; - vibrancy = "0.1696"; - vibrancy_darkness = "0.0"; - } - ]; - input-field = [ - { - size = "200, 50"; - position = "0, -80"; - monitor = "DP-1"; - dots_center = true; - fade_on_empty = true; - font_color = "rgb(202, 211, 245)"; - inner_color = "rgb(91, 96, 120)"; - outer_color = "rgb(24, 25, 38)"; - bothlock_color = -1; - outline_thickness = 5; - placeholder_text = ''Password...''; - shadow_passes = 2; - } - ]; - }; - }; - - home.sessionVariables = { - BROWSER = "firefox"; - EDITOR = "nano"; - TERMINAL = "kitty"; - NIXOS_OZONE_WL = "1"; - QT_QPA_PLATFORMTHEME = "gtk3"; - QT_SCALE_FACTOR = "1"; - MOZ_ENABLE_WAYLAND = "1"; - SDL_VIDEODRIVER = "wayland"; - QT_QPA_PLATFORM = "wayland-egl"; - QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; - QT_AUTO_SCREEN_SCALE_FACTOR = "1"; - GTK_CSD = "0"; -# WLR_DRM_DEVICES = "/dev/dri/card0"; -# WLR_NO_HARDWARE_CURSORS = "1"; - CLUTTER_BACKEND = "wayland"; - # WLR_RENDERER = "vulkan"; - XCURSOR_THEME = cursorTheme; - XCURSOR_SIZE = cursorSize; - GTK_THEME = gtkTheme; - XDG_CURRENT_DESKTOP = "Hyprland"; - XDG_SESSION_DESKTOP = "Hyprland"; - XDG_SESSION_TYPE = "wayland"; - GTK_USE_PORTAL = "1"; - NIXOS_XDG_OPEN_USE_PORTAL = "1"; - XDG_CACHE_HOME = "\${HOME}/.cache"; - XDG_CONFIG_HOME = "\${HOME}/.config"; - #XDG_BIN_HOME = "\${HOME}/.local/bin"; - XDG_DATA_HOME = "\${HOME}/.local/share"; - }; - - home.pointerCursor = { - gtk.enable = true; - package = cursorThemePkg; - name = cursorTheme; - size = cursorSize; - }; - - gtk = { - enable = true; - - cursorTheme = { - name = cursorTheme; # macOS-[BigSur, Monterey]-[ , White, White-Windows, Windows] - package = cursorThemePkg; - }; - - theme = { - name = gtkTheme; - package = gtkThemePkg; - }; - - iconTheme = { - name = iconTheme; - package = iconThemePkg; - }; - - gtk3.extraConfig = { - # gtk-application-prefer-dark-theme = true; - "AdwStyleManager:color-scheme" = "ADW_COLOR_SCHEME_PREFER_DARK"; - }; - - gtk4.extraConfig = { - # gtk-application-prefer-dark-theme = true; - "AdwStyleManager:color-scheme" = "ADW_COLOR_SCHEME_PREFER_DARK"; - }; - - }; -} \ No newline at end of file