parent
5e15502da0
commit
27a9c23600
2
LICENSE
2
LICENSE
|
@ -1,4 +1,4 @@
|
|||
Copyright (c) 2020 John Olheiser
|
||||
Copyright (c) 2023 John Olheiser
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# tmpl templates
|
||||
# devflake
|
||||
|
||||
Check out the various branches for some basic examples of templates.
|
||||
Create a simple `flake.nix` for `nix develop`
|
||||
|
||||
## License
|
||||
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
Delete this file and put something else here!
|
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs{{if unstable}}/nixpkgs-unstable{{end}}";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
flake-utils,
|
||||
nixpkgs,
|
||||
}:
|
||||
flake-utils.lib.eachDefaultSystem (
|
||||
system: let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in {
|
||||
devShells.default = pkgs.mkShell {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
{{- range $pkg := (splitList "," packages)}}
|
||||
{{trim $pkg}}
|
||||
{{- end}}
|
||||
];
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
15
tmpl.yaml
15
tmpl.yaml
|
@ -1,11 +1,8 @@
|
|||
# tmpl.yaml
|
||||
# Write any template args here to prompt the user for, giving any defaults/options as applicable
|
||||
|
||||
prompts:
|
||||
- id: name
|
||||
label: Name
|
||||
default: MyProject
|
||||
- id: lang
|
||||
label: Language
|
||||
default: Go
|
||||
- id: unstable
|
||||
label: Use unstable
|
||||
help: Blank for stable, non-blank for unstable
|
||||
- id: packages
|
||||
label: Packages
|
||||
help: nixpkgs delimited by comma
|
||||
|
||||
|
|
Loading…
Reference in New Issue