fix machines folder not beeing present yet
This commit is contained in:
@@ -5,13 +5,13 @@
|
||||
}:
|
||||
let
|
||||
machinesDirs =
|
||||
if builtins.pathExists (directory + /machines)
|
||||
then builtins.readDir (directory + /machines)
|
||||
if builtins.pathExists "${directory}/machines"
|
||||
then builtins.readDir "${directory}/machines"
|
||||
else { };
|
||||
|
||||
machineSettings = machineName:
|
||||
if builtins.pathExists (directory + /machines/${machineName}/settings.json)
|
||||
then builtins.fromJSON (builtins.readFile (directory + /machines/${machineName}/settings.json))
|
||||
if builtins.pathExists "${directory}/machines/${machineName}/settings.json"
|
||||
then builtins.fromJSON (builtins.readFile "${directory}/machines/${machineName}/settings.json")
|
||||
else { };
|
||||
|
||||
nixosConfigurations = lib.mapAttrs
|
||||
|
||||
Reference in New Issue
Block a user