mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-12-24 23:14:12 +03:00
47 lines
1.0 KiB
Nix
47 lines
1.0 KiB
Nix
{
|
|
lib,
|
|
self,
|
|
...
|
|
}: let
|
|
l = lib // builtins;
|
|
in {
|
|
flake = {
|
|
templates =
|
|
{
|
|
default = self.templates.simple;
|
|
simple = {
|
|
description = "Simple dream2nix flake";
|
|
path = ./simple;
|
|
welcomeText = ''
|
|
You just created a simple dream2nix package!
|
|
|
|
start with typing `nix flake show` to discover the projects attributes.
|
|
|
|
commands:
|
|
|
|
- `nix develop` <-- enters the devShell
|
|
- `nix build .#` <-- builds the default package (`.#default`)
|
|
|
|
|
|
Start hacking and -_- have some fun!
|
|
|
|
> dont forget to add nix `result` folder to your `.gitignore`
|
|
|
|
'';
|
|
};
|
|
v1-python = {
|
|
description = "Simple dream2nix python project";
|
|
path = ./v1-python;
|
|
};
|
|
}
|
|
// (
|
|
l.genAttrs
|
|
(self.lib.dlib.listDirs ../examples)
|
|
(name: {
|
|
description = "Example: ${name} template";
|
|
path = ../examples/${name};
|
|
})
|
|
);
|
|
};
|
|
}
|