Compare commits

...

10 Commits

Author SHA1 Message Date
d1ca548da0 flake.lock: Update
Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/0a7ffb28e5df5844d0e8039c9833d7075cdee792' (2024-06-16)
  → 'github:nix-community/home-manager/90ae324e2c56af10f20549ab72014804a3064c7f' (2024-07-11)
• Updated input 'nix-darwin':
    'github:LnL7/nix-darwin/29b3096a6e283d7e6779187244cb2a3942239fdf' (2024-06-17)
  → 'github:LnL7/nix-darwin/5ce8503cf402cf76b203eba4b7e402bea8e44abc' (2024-07-13)
• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/b60ebf54c15553b393d144357375ea956f89e9a9' (2024-06-16)
  → 'github:NixOS/nixpkgs/feb2849fdeb70028c70d73b848214b00d324a497' (2024-07-09)
• Updated input 'sops-nix':
    'github:Mic92/sops-nix/797ce4c1f45a85df6dd3d9abdc53f2691bea9251' (2024-06-16)
  → 'github:Mic92/sops-nix/67035a355b1d52d2d238501f8cc1a18706979760' (2024-07-08)
• Updated input 'sops-nix/nixpkgs':
    'github:NixOS/nixpkgs/3f84a279f1a6290ce154c5531378acc827836fbb' (2024-06-13)
  → 'github:NixOS/nixpkgs/4284c2b73c8bce4b46a6adf23e16d9e2ec8da4bb' (2024-07-05)
• Updated input 'sops-nix/nixpkgs-stable':
    'github:NixOS/nixpkgs/c884223af91820615a6146af1ae1fea25c107005' (2024-06-15)
  → 'github:NixOS/nixpkgs/550ac3e955c30fe96dd8b2223e37e0f5d225c927' (2024-07-06)
2024-07-13 10:58:41 -04:00
8f887e8da9 Flake: Formatting 2024-07-13 10:58:41 -04:00
a2ceaf2e2e Flake: Easier Overlay Spec 2024-07-13 10:58:41 -04:00
7e79913d5e Flake: Unify system config spec 2024-07-13 10:58:41 -04:00
471f2e298e universeair/flake: remove redundant/out of place unfree enable 2024-07-13 10:58:41 -04:00
7000183e98 Flake: Separate modules 2024-07-13 10:58:41 -04:00
bec7b9cc4d universeair: keybind to me-emacs 2024-07-13 10:58:41 -04:00
be0b31c429 nixosConfig: specialArgs = "inputs" -> "{inherit inputs;}" 2024-07-13 10:58:41 -04:00
5fed071e2f Flake: @attrs -> @inputs 2024-07-13 10:58:41 -04:00
7dbd900843 Flake: Reorganize overlays 2024-07-13 10:58:41 -04:00
7 changed files with 90 additions and 76 deletions

38
flake.lock generated
View File

@@ -66,11 +66,11 @@
]
},
"locked": {
"lastModified": 1718526747,
"narHash": "sha256-sKrD/utGvmtQALvuDj4j0CT3AJXP1idOAq2p+27TpeE=",
"lastModified": 1720734513,
"narHash": "sha256-neWQ8eNtLTd+YMesb7WjKl1SVCbDyCm46LUgP/g/hdo=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0a7ffb28e5df5844d0e8039c9833d7075cdee792",
"rev": "90ae324e2c56af10f20549ab72014804a3064c7f",
"type": "github"
},
"original": {
@@ -108,11 +108,11 @@
]
},
"locked": {
"lastModified": 1718662658,
"narHash": "sha256-AKG7BsqtVWDlefgzyKz7vjaKTLi4+bmTSBhowbQoZtM=",
"lastModified": 1720845312,
"narHash": "sha256-yPhAsJTpyoIPQZJGC8Fw8W2lAXyhLoTn+HP20bmfkfk=",
"owner": "LnL7",
"repo": "nix-darwin",
"rev": "29b3096a6e283d7e6779187244cb2a3942239fdf",
"rev": "5ce8503cf402cf76b203eba4b7e402bea8e44abc",
"type": "github"
},
"original": {
@@ -124,11 +124,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1718530797,
"narHash": "sha256-pup6cYwtgvzDpvpSCFh1TEUjw2zkNpk8iolbKnyFmmU=",
"lastModified": 1720542800,
"narHash": "sha256-ZgnNHuKV6h2+fQ5LuqnUaqZey1Lqqt5dTUAiAnqH0QQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b60ebf54c15553b393d144357375ea956f89e9a9",
"rev": "feb2849fdeb70028c70d73b848214b00d324a497",
"type": "github"
},
"original": {
@@ -156,27 +156,27 @@
},
"nixpkgs-stable_2": {
"locked": {
"lastModified": 1718478900,
"narHash": "sha256-v43N1gZLcGkhg3PdcrKUNIZ1L0FBzB2JqhIYEyKAHEs=",
"lastModified": 1720282526,
"narHash": "sha256-dudRkHPRivMNOhd04YI+v4sWvn2SnN5ODSPIu5IVbco=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c884223af91820615a6146af1ae1fea25c107005",
"rev": "550ac3e955c30fe96dd8b2223e37e0f5d225c927",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "release-23.11",
"ref": "release-24.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1718276985,
"narHash": "sha256-u1fA0DYQYdeG+5kDm1bOoGcHtX0rtC7qs2YA2N1X++I=",
"lastModified": 1720181791,
"narHash": "sha256-i4vJL12/AdyuQuviMMd1Hk2tsGt02hDNhA0Zj1m16N8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "3f84a279f1a6290ce154c5531378acc827836fbb",
"rev": "4284c2b73c8bce4b46a6adf23e16d9e2ec8da4bb",
"type": "github"
},
"original": {
@@ -201,11 +201,11 @@
"nixpkgs-stable": "nixpkgs-stable_2"
},
"locked": {
"lastModified": 1718506969,
"narHash": "sha256-Pm9I/BMQHbsucdWf6y9G3xBZh3TMlThGo4KBbeoeczg=",
"lastModified": 1720479166,
"narHash": "sha256-jqvhLDXzTLTHq9ZviFOpcTmXXmnbLfz7mWhgMNipMN4=",
"owner": "Mic92",
"repo": "sops-nix",
"rev": "797ce4c1f45a85df6dd3d9abdc53f2691bea9251",
"rev": "67035a355b1d52d2d238501f8cc1a18706979760",
"type": "github"
},
"original": {

111
flake.nix
View File

@@ -10,71 +10,76 @@
home-manager.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { self, nixpkgs, sops-nix, me-emacs, nix-darwin, home-manager }@attrs: let
hydraGitea = import ./overlays/hydra.nix;
nvidiaContainer = import ./overlays/nvidiacontainer.nix nixpkgs;
me-emacs-overlay = me-emacs.overlays.default;
outputs = { self, nixpkgs, sops-nix, me-emacs, nix-darwin, home-manager }@inputs: let
overlays = import ./overlays/default.nix inputs;
modules = import ./modules/default.nix inputs;
# Configuration for `nixpkgs`
nixpkgsConfig = {
config = { allowUnfree = true; };
};
overlays' = l: ({ config, pkgs, ... }: {
nixpkgs.overlays = l;
});
pkgs_linux-x86_64 = nixpkgs.legacyPackages."x86-linux";
pkgs_linux-aarch64 = nixpkgs.legacyPackages."aarch64-linux";
sysConfig = config: {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
} // config;
nixosSystem' = config: nixpkgs.lib.nixosSystem (sysConfig ({
} // config));
darwinSystem' = config: nix-darwin.lib.darwinSystem (sysConfig ({
system = "aarch64-darwin";
} // config));
homeConf' = config: home-manager.lib.homeManagerConfiguration config;
in {
nixosConfigurations = {
nixos = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = attrs;
modules =
[
({ config, pkgs, ... }: {
nixpkgs.overlays = [ hydraGitea nvidiaContainer ];
})
./machines/hippocampus/configuration.nix
sops-nix.nixosModules.sops
];
nixos = nixosSystem' {
modules =[
./machines/hippocampus/configuration.nix
(overlays' [
overlays.hydra
overlays.nvidiaContainer
])
modules.sops
];
};
universedesktop = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = attrs;
modules =
[
({ config, pkgs, ... }: {
nixpkgs.overlays = [ me-emacs-overlay ];
})
./machines/universedesktop/configuration.nix
sops-nix.nixosModules.sops
];
universedesktop = nixosSystem' {
modules = [
./machines/universedesktop/configuration.nix
(overlays' [
overlays.emacs
])
modules.sops
];
};
};
darwinConfigurations."UniverseAir" = nix-darwin.lib.darwinSystem {
system = "aarch64-darwin";
specialArgs = {
inputs = attrs;
darwinConfigurations = {
UniverseAir = darwinSystem' {
modules = [
./machines/universeair/configuration.nix
(overlays' [
overlays.emacs
])
modules.home-manager-darwin
];
};
modules = [
./machines/universeair/configuration.nix
({ config, pkgs, ... }: {
nixpkgs.overlays = [ me-emacs-overlay ];
})
home-manager.darwinModules.home-manager
{
nixpkgs = nixpkgsConfig;
}
];
};
homeConfigurations."universelaptop" = home-manager.lib.homeManagerConfiguration {
pkgs = pkgs_linux-aarch64;
homeConfigurations = {
universelaptop = homeConf' {
pkgs = pkgs_linux-aarch64;
# Specify your home configuration modules here, for example,
# the path to your home.nix.
modules = [ ./machines/asahi/home.nix ];
extraSpecialArgs = {
pkgs-x86_64 = pkgs_linux-x86_64;
inputs = attrs;
extraSpecialArgs = {
pkgs-x86_64 = pkgs_linux-x86_64;
inputs = inputs;
};
modules = [
./machines/asahi/home.nix
];
};
};
};

View File

@@ -2,7 +2,7 @@
services.skhd = {
enable = true;
skhdConfig = ''
cmd + shift - e : open '${pkgs.mac-emacs}/Applications/Emacs.app'
cmd + shift - e : open '${pkgs.me-emacs}/Applications/Emacs.app'
cmd + shift + ctrl - e : kitty -d ~ -1
'';
};

View File

@@ -2,9 +2,9 @@
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ lib, config, pkgs, nixpkgs, ... }: {
{ lib, config, pkgs, inputs, ... }: {
nix.settings.auto-optimise-store = true;
nix.registry.nixpkgs.flake = nixpkgs;
nix.registry.nixpkgs.flake = inputs.nixpkgs;
# Allow user-mode qemu for running riscv64 binaries
# boot.binfmt.emulatedSystems = [ "riscv64-linux" ];

View File

@@ -1,4 +1,4 @@
{ lib, config, pkgs, nixpkgs, ... }: {
{ lib, config, pkgs, ... }: {
nixpkgs.overlays = [(self: super: rec {
# Discord fix
discord = super.discord.override {

4
modules/default.nix Normal file
View File

@@ -0,0 +1,4 @@
inputs: {
sops = inputs.sops-nix.nixosModules.sops;
home-manager-darwin = inputs.home-manager.darwinModules.home-manager;
}

5
overlays/default.nix Normal file
View File

@@ -0,0 +1,5 @@
inputs: {
hydra = import ./hydra.nix;
nvidiaContainer = import ./nvidiacontainer.nix inputs.nixpkgs;
emacs = inputs.me-emacs.overlays.default;
}