From e3b134e48a2f358abca45ab62281517de665903d Mon Sep 17 00:00:00 2001 From: "Wyatt J. Miller" Date: Tue, 30 Dec 2025 21:48:46 -0500 Subject: [PATCH] added swaytreesave flake, fixed manual import, fixed infinite recursion --- flake.lock | 50 +++++++++++++++++++++++++++++++++++++++++++++++- flake.nix | 6 +++++- home/default.nix | 3 ++- home/neovim.nix | 6 +++++- home/sway.nix | 8 ++++++++ 5 files changed, 69 insertions(+), 4 deletions(-) diff --git a/flake.lock b/flake.lock index 52e2249..9c3ba3b 100644 --- a/flake.lock +++ b/flake.lock @@ -75,6 +75,20 @@ "type": "github" } }, + "flake-schemas": { + "locked": { + "lastModified": 1761577921, + "narHash": "sha256-eK3/xbUOrxp9fFlei09XNjqcdiHXxndzrTXp7jFpOk8=", + "rev": "47849c7625e223d36766968cc6dc23ba0e135922", + "revCount": 107, + "type": "tarball", + "url": "https://api.flakehub.com/f/pinned/DeterminateSystems/flake-schemas/0.2.0/019a4a84-544d-7c59-b26d-e334e320c932/source.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://flakehub.com/f/DeterminateSystems/flake-schemas/%2A" + } + }, "flake-utils": { "inputs": { "systems": "systems" @@ -236,6 +250,20 @@ "type": "github" } }, + "nixpkgs_5": { + "locked": { + "lastModified": 1766201043, + "narHash": "sha256-eplAP+rorKKd0gNjV3rA6+0WMzb1X1i16F5m5pASnjA=", + "rev": "b3aad468604d3e488d627c0b43984eb60e75e782", + "revCount": 904049, + "type": "tarball", + "url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.2511.904049%2Brev-b3aad468604d3e488d627c0b43984eb60e75e782/019b3f6c-8b33-7edb-b858-9979590f270b/source.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://flakehub.com/f/NixOS/nixpkgs/%2A" + } + }, "root": { "inputs": { "aagl": "aagl", @@ -244,7 +272,8 @@ "home-manager": "home-manager_2", "nix-flatpak": "nix-flatpak", "nixpkgs": "nixpkgs_3", - "rust-overlay": "rust-overlay_2" + "rust-overlay": "rust-overlay_2", + "swaytreesave": "swaytreesave" } }, "rust-overlay": { @@ -283,6 +312,25 @@ "type": "github" } }, + "swaytreesave": { + "inputs": { + "flake-schemas": "flake-schemas", + "nixpkgs": "nixpkgs_5" + }, + "locked": { + "lastModified": 1767148467, + "narHash": "sha256-W0O7SWq8ucokt4ctEAEvRvNoSM/oF7fBfb2kTN+lwTs=", + "ref": "refs/heads/master", + "rev": "0f4bb9bb450b28aa4f29d5eb2062deac6c26687a", + "revCount": 4, + "type": "git", + "url": "https://scm.wyattjmiller.com/wymiller/swaytreesave-nix.git" + }, + "original": { + "type": "git", + "url": "https://scm.wyattjmiller.com/wymiller/swaytreesave-nix.git" + } + }, "systems": { "locked": { "lastModified": 1681028828, diff --git a/flake.nix b/flake.nix index 80af847..00cfd32 100644 --- a/flake.nix +++ b/flake.nix @@ -17,6 +17,9 @@ url = "github:ezKEa/aagl-gtk-on-nix"; inputs.nixpkgs.follows = "nixpkgs"; }; + + # My personal flakes + swaytreesave.url = "git+https://scm.wyattjmiller.com/wymiller/swaytreesave-nix.git"; }; outputs = inputs @ { @@ -28,12 +31,13 @@ ghostty, rust-overlay, aagl, + swaytreesave, ... }: let userName = "wyatt"; userEmail = "wyatt@wyattjmiller.com"; extraSpecialArgs = { - inherit userName userEmail ghostty; + inherit userName userEmail ghostty swaytreesave; }; myOverlays = { ... }: { diff --git a/home/default.nix b/home/default.nix index 19219a2..720c870 100644 --- a/home/default.nix +++ b/home/default.nix @@ -4,6 +4,7 @@ userName, userEmail, ghostty, + swaytreesave, ... }: let # Have a file sturcture that holds all the configuration files that can't be configured by Nix @@ -13,7 +14,7 @@ }; in { # Import sub modules - imports = map (module: import module {inherit lib pkgs dirs userName userEmail ghostty;}) [ + imports = [ ./atuin.nix ./shell.nix ./packages diff --git a/home/neovim.nix b/home/neovim.nix index 0efa653..eebfd50 100644 --- a/home/neovim.nix +++ b/home/neovim.nix @@ -1,4 +1,8 @@ -{dirs, ...}: { +{...}: let + dirs = { + defaults = ../defaults; + }; +in { programs.neovim = { enable = true; defaultEditor = true; diff --git a/home/sway.nix b/home/sway.nix index 8e81b1d..7827aa8 100644 --- a/home/sway.nix +++ b/home/sway.nix @@ -1,6 +1,7 @@ { lib, pkgs, + swaytreesave, ... }: let dirs = { @@ -15,6 +16,12 @@ hash = "sha256-ZDFbI69ECsUTjbhlw2kHRufZbQMu+FQSMmncCJ5pagg="; }; in { + imports = [ + swaytreesave.homeManagerModules.default + ]; + + programs.swaytreesave.enable = if pkgs.stdenv.isLinux then true else false; + wayland.windowManager.sway = { enable = pkgs.stdenv.isLinux; extraOptions = []; # Extra arguments to pass into sway. If sway goes haywire, we might need something in here @@ -148,4 +155,5 @@ in { enable = pkgs.stdenv.isLinux; systemd.enable = true; }; + }