Commit Graph

21 Commits

Author SHA1 Message Date
Johannes Kirschbauer
df0b8cfd45 Feat(clanLib): init types {uniqueDeferredSerializableModule} 2025-05-21 18:41:14 +02:00
lassulus
5feccf4e57 Refactor select with new maybe selector
This is a great refactor of the select functionality in the flake class.
This now uses the same parser as the nix code, but runs it in python for
nice stacktraces.

Also we now have a maybe selector which can be used by prepending the
selector with a ?

Tests have been expanded to make sure the code is more stable and easier
to understand
2025-04-25 16:26:45 +10:00
Michael Hoang
6de4735c81 build-clan: support constructing darwinConfigurations 2025-04-08 08:53:29 +02:00
Johannes Kirschbauer
69078433cd chore(lib/select): move into subfolder with a test file 2025-04-02 12:37:49 +02:00
Johannes Kirschbauer
2ab53b05fe chore(lib/treewide): cleanup directory struture of lib. See lib/readme.md for details 2025-04-02 11:11:21 +02:00
Johannes Kirschbauer
40740860c0 feat(lib): init callLib; helper to bootstrap clanLib 2025-03-30 16:11:04 +02:00
Johannes Kirschbauer
68ae27899a feat(clan/services): init test-suite for eval test 2025-03-29 13:25:19 +01:00
DavHau
3ec028d672 tests: reduce unnecessary rebuilds of several tests
Some test were referring to the whole source code via ${self} which amde them rebuild on every single commit.

This is not mitigated by introduceing `self.filter { include = [...]; }` allowin to a content addressed subset of the source code in tests.
2025-01-17 17:00:18 +07:00
Johannes Kirschbauer
fca193073e lib.values: init getPrio
This function can be used to get the priority of all values within a module
2024-12-04 17:37:23 +01:00
Johannes Kirschbauer
8fd09b8403 Add build-clan module 2024-08-03 12:05:09 +02:00
Johannes Kirschbauer
26c655ff3c Add settings.json back 2024-06-25 12:23:29 +00:00
Johannes Kirschbauer
13c3169b41 lib: eval clan module as lib function 2024-06-24 15:47:25 +02:00
Jörg Thalheim
e296a3019d re-format with nixfmt 2024-03-17 19:48:49 +01:00
DavHau
bf176ad277 api/machines: allow importing extra modules
- add top-level option `clanImports` to clanCore
- clanImports can be set and checked as any other option
- buildClan resolves the clanImports from the settings.json before calling evalModules to prevent infinite recursions
- new endpoint PUT machines/{name}/schema to allow getting the schema for a specific list of imports
- to retrieve the currently imported modules, cimply do a GET or PU on machines/{name}/config which will return `clanImports` as part of the config

Still missing: get list of available modules
2023-10-25 16:36:30 +01:00
DavHau
03808d9fbc buildClan: fix missing argument clan 2023-09-02 18:24:34 +02:00
Jörg Thalheim
1d496c6363 buildClan: also import clanCore module 2023-08-30 16:41:50 +02:00
Jörg Thalheim
72768573db drop non-existent clan modules 2023-08-29 22:30:33 +02:00
Jörg Thalheim
7c21453b17 lib.buildClan: fix flake reference 2023-08-29 22:27:13 +02:00
Jörg Thalheim
a4e182debf clan template: reduce autogenerate code to a minimum 2023-08-29 13:54:06 +00:00
DavHau
7262208a4c clanLib.jsonschema: move tests from pkgs/clan-cli 2023-08-09 16:05:33 +02:00
lassulus
96067a789d move modules into nixosModules, add autoimport 2023-08-02 10:24:01 +02:00