improve rust template for ensuring package overriable
This commit is contained in:
parent
dc5dfddf74
commit
18bfe1ce9a
6 changed files with 100 additions and 38 deletions
13
templates/rust/nix/lib.nix
Normal file
13
templates/rust/nix/lib.nix
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
flip,
|
||||
pipe,
|
||||
splitString,
|
||||
head,
|
||||
listToAttrs,
|
||||
nameValuePair,
|
||||
getAttrFromPath,
|
||||
...
|
||||
}: {
|
||||
genFunctionArgs = flip pipe [(map (flip pipe [(splitString ".") head (flip nameValuePair false)])) listToAttrs];
|
||||
genInputsWith = pkgs: map (flip pipe [(splitString ".") (flip getAttrFromPath pkgs)]);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue