@@ -2,19 +2,16 @@ module mcl.commands.deploy_spec;
22
33import std.algorithm : filter;
44import std.logger : infof, warningf;
5- import std.file : exists, readText ;
5+ import std.file : exists;
66import std.path : buildPath;
7- import std.file : writeFile = write;
8- import std.json : parseJSON, JSONOptions;
97
108import mcl.utils.process : spawnProcessInline;
119import mcl.utils.path : resultDir;
12- import mcl.utils.env : parseEnv;
1310import mcl.utils.cachix : cachixNixStoreUrl, DeploySpec, createMachineDeploySpec;
1411import mcl.utils.tui : bold;
15- import mcl.utils.json : toJSON, fromJSON, tryDeserializeFromJsonFile ;
12+ import mcl.utils.json : tryDeserializeFromJsonFile, writeJsonFile ;
1613
17- import mcl.commands.ci_matrix : flakeAttr, params, Params, nixEvalJobs, SupportedSystem;
14+ import mcl.commands.ci_matrix : flakeAttr, params, nixEvalJobs, SupportedSystem;
1815
1916export void deploy_spec ()
2017{
@@ -42,7 +39,7 @@ export void deploy_spec()
4239 throw new Exception (" Some Nixos configurations are not in cachix. Please cache them first." );
4340
4441 spec = nixosConfigs.createMachineDeploySpec();
45- writeFile(deploySpecFile, spec.toJSON.toPrettyString(JSONOptions.doNotEscapeSlashes) );
42+ writeJsonFile(spec, deploySpecFile );
4643 }
4744 else
4845 {
0 commit comments