Getting very simple functions first.

This commit is contained in:
Yaro Kasear 2025-07-20 13:00:43 -05:00
parent 9a5044959f
commit 219dd073ff
4 changed files with 20 additions and 8 deletions

View file

@ -1 +0,0 @@
locations: builtins.attrNames locations

View file

@ -0,0 +1,9 @@
{ data, lib }:
let
mkLocationsList = locations: builtins.attrNames locations;
mkLocationIndex = data: location: lib.lists.findFirstIndex (x: x == location) null (mkLocationsList data);
in
{
inherit mkLocationsList mkLocationIndex;
}