diff --git a/flake.lock b/flake.lock index b0ed81a..0af12f5 100644 --- a/flake.lock +++ b/flake.lock @@ -1674,6 +1674,7 @@ "nixpkgs-wayland": "nixpkgs-wayland", "resume": "resume", "rio-term": "rio-term", + "rust-overlay": "rust-overlay_4", "snowfall-lib": "snowfall-lib", "solaar": "solaar", "spicetify-nix": "spicetify-nix", @@ -1744,6 +1745,26 @@ "type": "github" } }, + "rust-overlay_4": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1729045942, + "narHash": "sha256-HjmK0x5Zm2TK2vFpC7XBM2e3EDNVnAIuEoU2FkeN8xw=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "9de3cea452d2401d6f93c06ad985178a4e11d1fc", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + }, "snowfall-lib": { "inputs": { "flake-compat": "flake-compat_6", diff --git a/flake.nix b/flake.nix index 182948b..1f3dc65 100644 --- a/flake.nix +++ b/flake.nix @@ -106,6 +106,11 @@ url = "github:Gerg-L/spicetify-nix"; inputs.nixpkgs.follows = "nixpkgs"; }; + + rust-overlay = { + url = "github:oxalica/rust-overlay"; + inputs.nixpkgs.follows = "nixpkgs"; + }; }; outputs = inputs @ { @@ -117,7 +122,7 @@ inherit inputs; src = ./.; - overlays = [inputs.nixpkgs-wayland.overlay]; + overlays = [inputs.nixpkgs-wayland.overlay inputs.rust-overlay.overlays.default]; snowfall = { namespace = "custom"; diff --git a/homes/x86_64-linux/zoey@earth/default.nix b/homes/x86_64-linux/zoey@earth/default.nix index bada23b..e929cc8 100644 --- a/homes/x86_64-linux/zoey@earth/default.nix +++ b/homes/x86_64-linux/zoey@earth/default.nix @@ -97,6 +97,8 @@ pkgs.grim pkgs.slurp + pkgs.neovide + pkgs.xfce.thunar pkgs.feh pkgs.nitch diff --git a/modules/home/apps/helpers/ags/default.nix b/modules/home/apps/helpers/ags/default.nix index 1f23329..f2f1e47 100644 --- a/modules/home/apps/helpers/ags/default.nix +++ b/modules/home/apps/helpers/ags/default.nix @@ -59,7 +59,7 @@ in { Description = "Aylur's Gtk Shell"; PartOf = [ "tray.target" - "graphical-session.target" + "hyprland-session.target" ]; }; Service = { @@ -67,7 +67,7 @@ in { ExecStart = "${config.programs.ags.package}/bin/ags"; Restart = "on-failure"; }; - Install.WantedBy = ["graphical-session.target"]; + Install.WantedBy = ["hyprland-session.target"]; }; }; } diff --git a/modules/home/apps/tools/neovim/config/lazyvim.json b/modules/home/apps/tools/neovim/config/lazyvim.json index e009e9a..cdad498 100644 --- a/modules/home/apps/tools/neovim/config/lazyvim.json +++ b/modules/home/apps/tools/neovim/config/lazyvim.json @@ -11,6 +11,7 @@ "lazyvim.plugins.extras.lang.docker", "lazyvim.plugins.extras.lang.haskell", "lazyvim.plugins.extras.lang.java", + "lazyvim.plugins.extras.lang.toml", "lazyvim.plugins.extras.lang.json", "lazyvim.plugins.extras.lang.markdown", "lazyvim.plugins.extras.lang.nix", diff --git a/modules/home/apps/tools/neovim/config/lua/config/options.lua b/modules/home/apps/tools/neovim/config/lua/config/options.lua index 3ea1454..54d2a06 100644 --- a/modules/home/apps/tools/neovim/config/lua/config/options.lua +++ b/modules/home/apps/tools/neovim/config/lua/config/options.lua @@ -1,3 +1,8 @@ -- Options are automatically loaded before lazy.nvim startup -- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua -- Add any additional options here + +if vim.g.neovide then + -- Put anything you want to happen only in Neovide here + vim.o.guifont = "Iosevka,Noto_Color_Emoji:h14:b" +end diff --git a/modules/home/apps/tools/neovim/config/lua/plugins/core.lua b/modules/home/apps/tools/neovim/config/lua/plugins/core.lua index 6099eb4..f78a2c2 100644 --- a/modules/home/apps/tools/neovim/config/lua/plugins/core.lua +++ b/modules/home/apps/tools/neovim/config/lua/plugins/core.lua @@ -17,11 +17,14 @@ return { }) end, }, + "direnv/direnv.vim", { "stevearc/conform.nvim", opts = { formatters_by_ft = { nix = { "alejandra" }, + typescript = { "prettierd" }, + javascript = { "prettierd" }, }, }, }, @@ -32,22 +35,25 @@ return { -- optional: provides snippets for the snippet source dependencies = "rafamadriz/friendly-snippets", - -- use a release tag to download pre-built binaries - version = "v0.*", - -- OR build from source, requires nightly: https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust - -- build = 'cargo build --release', + build = "cargo build --release", opts = { keymap = { show = "", accept = "", - select_prev = { "", "" }, - select_next = { "", "" }, + select_prev = { "", "", "" }, + select_next = { "", "", "" }, snippet_forward = "", snippet_backward = "", }, + windows = { + documentation = { + auto_show = true, + }, + }, + highlight = { -- sets the fallback highlight groups to nvim-cmp's highlight groups -- useful for when your theme doesn't support blink.cmp diff --git a/modules/home/apps/tools/neovim/default.nix b/modules/home/apps/tools/neovim/default.nix index e979073..83d008a 100644 --- a/modules/home/apps/tools/neovim/default.nix +++ b/modules/home/apps/tools/neovim/default.nix @@ -52,6 +52,8 @@ in { # LSP lua-language-server nixd + (pkgs.rust-bin.selectLatestNightlyWith + (toolchain: toolchain.minimal)) rust-analyzer vscode-langservers-extracted nodePackages.vscode-json-languageserver diff --git a/modules/home/wms/hyprland/default.nix b/modules/home/wms/hyprland/default.nix index c555005..81b3d23 100644 --- a/modules/home/wms/hyprland/default.nix +++ b/modules/home/wms/hyprland/default.nix @@ -12,9 +12,9 @@ with lib.custom; let cfg = config.wms.hyprland; mkService = recursiveUpdate { - Unit.PartOf = ["graphical-session.target"]; - Unit.After = ["graphical-session.target"]; - Install.WantedBy = ["graphical-session.target"]; + Unit.PartOf = ["hyprland-session.target"]; + Unit.After = ["hyprland-session.target"]; + Install.WantedBy = ["hyprland-session.target"]; }; mod = "SUPER"; @@ -47,21 +47,20 @@ in { enable = true; xwayland.enable = true; - systemd = { - enable = true; - variables = ["--all"]; - extraCommands = [ - "systemctl --user stop graphical-session.target" - "systemctl --user start hyprland-session.target" - ]; - }; + # systemd = { + # enable = true; + # enableXdgAutostart = true; + # variables = ["-all"]; + # }; }; wayland.windowManager.hyprland.settings = with colors; { exec-once = [ # "pw-loopback -C \"alsa_input.pci-0000_0d_00.4.analog-stereo\" -P \"Scarlett Solo (3rd Gen.) Headphones / Line 1-2\"" - "sway-audio-idle-inhibit" - "zen-browser" + # "systemctl --user import-environment DISPLAY WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" + "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" + "systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" + "zen" "sleep 6;telegram-desktop" "sleep 10;thunderbird" "vesktop" @@ -69,6 +68,12 @@ in { "slack" ]; + env = [ + "XDG_SESSION_TYPE,wayland" + "XDG_SESSION_DESKTOP,Hyprland" + "XDG_CURRENT_DESKTOP,Hyprland" + ]; + bind = [ ''${mod},RETURN,exec,${pkgs.kitty}/bin/kitty'' @@ -174,7 +179,7 @@ in { no_hardware_cursors = true; }; - monitor = ["DP-1,2560x1440@240,0x0,1,bitdepth,10" "HDMI-A-1,disable" "DP-2,disable"]; + monitor = ["DP-1,2560x1440@240,0x0,1" "HDMI-A-1,disable" "DP-2,disable"]; layerrule = [ "blur, ^(gtk-layer-shell)$" diff --git a/modules/nixos/protocols/wayland/default.nix b/modules/nixos/protocols/wayland/default.nix index 2abbff6..96a5fbf 100644 --- a/modules/nixos/protocols/wayland/default.nix +++ b/modules/nixos/protocols/wayland/default.nix @@ -33,6 +33,10 @@ in { }; }; + programs.hyprland = { + enable = true; + }; + environment = { variables = { NIXOS_OZONE_WL = "1"; @@ -65,17 +69,15 @@ in { hardware.pulseaudio.support32Bit = true; - xdg.portal = { - enable = true; - config.common.default = "*"; - wlr.enable = true; - extraPortals = [ - pkgs.xdg-desktop-portal-gtk - pkgs.xdg-desktop-portal-wlr - # inputs.hyprland.packages.${pkgs.system}.xdg-desktop-portal-hyprland - pkgs.xdg-desktop-portal-hyprland - pkgs.xwaylandvideobridge - ]; - }; + # xdg.portal = { + # enable = true; + # wlr.enable = false; + # config.common.default = "*"; + # extraPortals = [ + # pkgs.xdg-desktop-portal-gtk + # # pkgs.xdg-desktop-portal-wlr + # pkgs.xwaylandvideobridge + # ]; + # }; }; } diff --git a/packages/vesktop/default.nix b/packages/vesktop/default.nix index a555ee4..d2becf8 100644 --- a/packages/vesktop/default.nix +++ b/packages/vesktop/default.nix @@ -28,8 +28,8 @@ stdenv.mkDerivation (finalAttrs: { src = fetchFromGitHub { owner = "Vencord"; repo = "Vesktop"; - rev = "d008f903995c802cb5addd99bd759878c8a3491a"; - hash = "sha256-oQr0k+0dOuJgwg51hr3O/OZoD66XOctQK82bu+MY+zE="; + rev = "8993b0d"; + hash = "sha256-R8MT8Z5oHJTAXE2SAcq+yAeVkUEhisLOUaUyMAwFy4w="; }; # NOTE: This requires pnpm 8.10.0 or newer diff --git a/systems/x86_64-linux/earth/default.nix b/systems/x86_64-linux/earth/default.nix index c4ec9ef..c71809e 100644 --- a/systems/x86_64-linux/earth/default.nix +++ b/systems/x86_64-linux/earth/default.nix @@ -25,6 +25,7 @@ hardware.audio.enable = true; hardware.nvidia.enable = true; + hardware.keyboard.qmk.enable = true; programs.nix-ld.enable = true;