This commit is contained in:
Jana Dönszelmann 2025-05-28 11:27:06 +02:00
parent f289c537d8
commit ddb92ea0c5
No known key found for this signature in database
12 changed files with 918 additions and 643 deletions

View file

@ -1,9 +1,11 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/release-24.11";
# nixpkgs.url = "github:NixOS/nixpkgs/release-24.11";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
home-manager = {
url = "github:nix-community/home-manager/release-24.11";
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
@ -30,18 +32,20 @@
inputs.rahul-config.follows = "rahul-config";
};
rahul-config.url = "github:jdonszelmann/nix-config";
nixgl.url = "github:nix-community/nixGL";
};
outputs =
{
home-manager,
nixpkgs,
flake-utils,
nixvim,
t,
dumpasm,
jujutsu,
...
{ home-manager
, nixpkgs
, flake-utils
, nixvim
, t
, dumpasm
, jujutsu
, nixgl
, ...
}@inputs:
let
homeManagerModules = [ nixvim.homeManagerModules.nixvim ];
@ -52,6 +56,7 @@
inherit system;
config.allowUnfree = true;
overlays = [
nixgl.overlay
(_: _: {
custom = {
t = t.packages.${system}.default;
@ -74,28 +79,29 @@
}
);
in
flake-utils.lib.eachDefaultSystem (system: rec {
formatter = legacyPackages.nixfmt-classic;
legacyPackages = pkgsForSystem system;
pkgs = legacyPackages;
devShells.default = pkgs.mkShell {
buildInputs = with pkgs; [
(pkgs.writeShellScriptBin "fast-repl" ''
source /etc/set-environment
nix repl --file "${./.}/repl.nix" $@
'')
flake-utils.lib.eachDefaultSystem
(system: rec {
formatter = legacyPackages.nixfmt-classic;
legacyPackages = pkgsForSystem system;
pkgs = legacyPackages;
devShells.default = pkgs.mkShell {
buildInputs = with pkgs; [
(pkgs.writeShellScriptBin "fast-repl" ''
source /etc/set-environment
nix repl --file "${./.}/repl.nix" $@
'')
(pkgs.writeShellScriptBin "apply-home" ''
export NIX_BUILD_CORES=$(($(nproc) * 2))
nix run .#home-manager -- switch --flake .#$@ -j $(nproc) --cores $(nproc)
'')
(pkgs.writeShellScriptBin "apply-home" ''
export NIX_BUILD_CORES=$(($(nproc) * 2))
nix run .#home-manager -- switch --flake .#$@ -j $(nproc) --cores $(nproc)
'')
(pkgs.writeShellScriptBin "apply" ''
apply-home $(hostname -f)
'')
];
};
})
(pkgs.writeShellScriptBin "apply" ''
apply-home $(hostname -f)
'')
];
};
})
// {
homeConfigurations = {