Skip to content

Commit fbe8682

Browse files
committed
Apply nixfmt
1 parent ce8198c commit fbe8682

1 file changed

Lines changed: 20 additions & 17 deletions

File tree

modules/zrepl.nix

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,28 @@ let
1212
pred: v: if isAttrs v then filterAttrs pred (mapAttrs (path: filterAttrsRec pred) v) else v;
1313

1414
# Fields valid only for ssh+stdinserver connect
15-
sshConnectFields = [ "host" "user" "identity_file" "port" ];
15+
sshConnectFields = [
16+
"host"
17+
"user"
18+
"identity_file"
19+
"port"
20+
];
1621
# Fields valid only for local connect
17-
localConnectFields = [ "listener_name" "client_identity" ];
22+
localConnectFields = [
23+
"listener_name"
24+
"client_identity"
25+
];
1826
# Fields valid only for local serve
1927
localServeFields = [ "listener_name" ];
2028
# Fields valid only for stdinserver serve
2129
stdinserverServeFields = [ "client_identities" ];
2230

2331
filterConnect =
24-
c:
25-
if c.type == "local" then
26-
removeAttrs c sshConnectFields
27-
else
28-
removeAttrs c localConnectFields;
32+
c: if c.type == "local" then removeAttrs c sshConnectFields else removeAttrs c localConnectFields;
2933

3034
filterServe =
3135
s:
32-
if s.type == "local" then
33-
removeAttrs s stdinserverServeFields
34-
else
35-
removeAttrs s localServeFields;
36+
if s.type == "local" then removeAttrs s stdinserverServeFields else removeAttrs s localServeFields;
3637

3738
filterJob =
3839
job:
@@ -219,12 +220,14 @@ in
219220

220221
jobs = mapAttrsToList (
221222
n: v:
222-
filterJob (filterAttrsRec (n: v: v != null) (
223-
{
224-
name = n;
225-
}
226-
// v
227-
))
223+
filterJob (
224+
filterAttrsRec (n: v: v != null) (
225+
{
226+
name = n;
227+
}
228+
// v
229+
)
230+
)
228231
) cfg.jobs;
229232

230233
});

0 commit comments

Comments
 (0)