added notes and rebuilt flake
This commit is contained in:
34
README.md
34
README.md
@@ -1,7 +1,39 @@
|
|||||||
# A Dendritic Nix Flake
|
# A Dendritic Nix Flake
|
||||||
|
|
||||||
|
Regenerate flake and switch to it.
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
nix run ".#write-flake"
|
nix run .#write-flake
|
||||||
nix flake check
|
nix flake check
|
||||||
home-manager switch --flake .#desktop
|
home-manager switch --flake .#desktop
|
||||||
```
|
```
|
||||||
|
|
||||||
|
```shell
|
||||||
|
nix flake show --all-systems
|
||||||
|
```
|
||||||
|
|
||||||
|
## Mechanics
|
||||||
|
|
||||||
|
### Flake
|
||||||
|
|
||||||
|
The top-level flake is created using [flake-file](https://flake-file.oeiuwq.com/)
|
||||||
|
|
||||||
|
```shell
|
||||||
|
nix flake init -t github:vic/flake-file#default
|
||||||
|
...
|
||||||
|
nix run ".#write-flake"
|
||||||
|
```
|
||||||
|
|
||||||
|
This uses `inputs.flake-parts.lib.mkFlake` to create the flake.
|
||||||
|
|
||||||
|
The modules are automatically imported from the `./modules` using [import-tree](https://import-tree.oeiuwq.com/).
|
||||||
|
|
||||||
|
|
||||||
|
### [Home Manager](https://flake.parts/options/home-manager.html)
|
||||||
|
|
||||||
|
Uses the home-manager module of flake-parts, which is imported in `modules/home-manager/flake-parts.nix`
|
||||||
|
|
||||||
|
Looks for options:
|
||||||
|
|
||||||
|
- `flake.homeConfigurations`
|
||||||
|
- `flake.homeModules`
|
||||||
|
|||||||
62
flake.lock
generated
62
flake.lock
generated
@@ -2,11 +2,11 @@
|
|||||||
"nodes": {
|
"nodes": {
|
||||||
"flake-file": {
|
"flake-file": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1771017549,
|
"lastModified": 1772863627,
|
||||||
"narHash": "sha256-n68HeYEQJ67hMH2LPI0cERD2pkpNe5dyeOGg11uZ7rc=",
|
"narHash": "sha256-Jx4FIAwp3E1cUKQ+a9DfVhRU+ry/IyjYNJbtyz+ld5U=",
|
||||||
"owner": "vic",
|
"owner": "vic",
|
||||||
"repo": "flake-file",
|
"repo": "flake-file",
|
||||||
"rev": "9d89918faacdbd2ce26d0aa7298da0fecad8b437",
|
"rev": "51181d48fcc08f5cc97b64859b91699d70c59d11",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -22,11 +22,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1769996383,
|
"lastModified": 1772408722,
|
||||||
"narHash": "sha256-AnYjnFWgS49RlqX7LrC4uA+sCCDBj0Ry/WOJ5XWAsa0=",
|
"narHash": "sha256-rHuJtdcOjK7rAHpHphUb1iCvgkU3GpfvicLMwwnfMT0=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-parts",
|
||||||
"rev": "57928607ea566b5db3ad13af0e57e921e6b12381",
|
"rev": "f20dc5d9b8027381c474144ecabc9034d6a839a3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -58,11 +58,11 @@
|
|||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1771102945,
|
"lastModified": 1772845525,
|
||||||
"narHash": "sha256-e5NfW8NhC3qChR8bHVni/asrig/ZFzd1wzpq+cEE/tg=",
|
"narHash": "sha256-Dp5Ir2u4jJDGCgeMRviHvEQDe+U37hMxp6RSNOoMMPc=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "ff5e5d882c51f9a032479595cbab40fd04f56399",
|
"rev": "27b93804fbef1544cb07718d3f0a451f4c4cd6c0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -73,11 +73,11 @@
|
|||||||
},
|
},
|
||||||
"import-tree": {
|
"import-tree": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1771045967,
|
"lastModified": 1772344373,
|
||||||
"narHash": "sha256-oYO4poyw0Sb/db2PigqugMlDwsvwLg6CSpFrMUWxA3Q=",
|
"narHash": "sha256-OQQ1MhB9t1J71b2wxRRTdH/Qd8UGG0p+dGspfCf5U1c=",
|
||||||
"owner": "vic",
|
"owner": "vic",
|
||||||
"repo": "import-tree",
|
"repo": "import-tree",
|
||||||
"rev": "c968d3b54d12cf5d9c13f16f7c545a06c9d1fde6",
|
"rev": "10fda59eee7d7970ec443b925f32a1bc7526648c",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -109,11 +109,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1770841267,
|
"lastModified": 1772542754,
|
||||||
"narHash": "sha256-9xejG0KoqsoKEGp2kVbXRlEYtFFcDTHjidiuX8hGO44=",
|
"narHash": "sha256-WGV2hy+VIeQsYXpsLjdr4GvHv5eECMISX1zKLTedhdg=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "ec7c70d12ce2fc37cb92aff673dcdca89d187bae",
|
"rev": "8c809a146a140c5c8806f13399592dbcb1bb5dc4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -125,11 +125,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1771177547,
|
"lastModified": 1772771118,
|
||||||
"narHash": "sha256-erxy9meNKMaKpKQpl8KfhZsVY4EtR4eaHT94jY98Ty0=",
|
"narHash": "sha256-SDEGkbscgwFhxzfvNdDNcvsA82gAQcyOh0/BZOb6fWg=",
|
||||||
"rev": "ac055f38c798b0d87695240c7b761b82fc7e5bc2",
|
"rev": "e38213b91d3786389a446dfce4ff5a8aaf6012f2",
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.05pre946843.ac055f38c798/nixexprs.tar.xz"
|
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.05pre958959.e38213b91d37/nixexprs.tar.xz"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
@@ -147,8 +147,7 @@
|
|||||||
"nixpkgs-lib": [
|
"nixpkgs-lib": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"sops-nix": "sops-nix",
|
"sops-nix": "sops-nix"
|
||||||
"systems": "systems_2"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"sops-nix": {
|
"sops-nix": {
|
||||||
@@ -158,11 +157,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1770683991,
|
"lastModified": 1772944399,
|
||||||
"narHash": "sha256-xVfPvXDf9QN3Eh9dV+Lw6IkWG42KSuQ1u2260HKvpnc=",
|
"narHash": "sha256-xTzsSd3r5HBeufSZ3fszAn0ldfKctvsYG7tT2YJg5gY=",
|
||||||
"owner": "Mic92",
|
"owner": "Mic92",
|
||||||
"repo": "sops-nix",
|
"repo": "sops-nix",
|
||||||
"rev": "8b89f44c2cc4581e402111d928869fe7ba9f7033",
|
"rev": "c8e69670b316d6788e435a3aa0bda74eb1b82cc0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -185,21 +184,6 @@
|
|||||||
"repo": "default",
|
"repo": "default",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
|
||||||
"systems_2": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1681028828,
|
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-systems",
|
|
||||||
"repo": "default",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": "root",
|
"root": "root",
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
# DO-NOT-EDIT. This file was auto-generated using github:vic/flake-file.
|
# DO-NOT-EDIT. This file was auto-generated using github:vic/flake-file.
|
||||||
# Use `nix run .#write-flake` to regenerate it.
|
# Use `nix run .#write-flake` to regenerate it.
|
||||||
{
|
{
|
||||||
description = "A dendritic setup.";
|
|
||||||
|
|
||||||
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } (inputs.import-tree ./modules);
|
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } (inputs.import-tree ./modules);
|
||||||
|
|
||||||
@@ -23,7 +22,6 @@
|
|||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
url = "github:Mic92/sops-nix";
|
url = "github:Mic92/sops-nix";
|
||||||
};
|
};
|
||||||
systems.url = "github:nix-systems/default";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,9 @@
|
|||||||
{ inputs, ... }:
|
{ inputs, ... }:
|
||||||
{
|
{
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
|
# https://github.com/vic/flake-file/tree/main/modules/dendritic
|
||||||
inputs.flake-file.flakeModules.dendritic
|
inputs.flake-file.flakeModules.dendritic
|
||||||
];
|
];
|
||||||
flake-file.description = "A dendritic setup.";
|
|
||||||
|
|
||||||
# flake.flakeModule = {
|
|
||||||
# imports = (inputs.import-tree ./home-manager);
|
|
||||||
# };
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user