mirror of
https://gitlab.com/TECHNOFAB/soonix.git
synced 2026-11-01 11:12:19 +01:00
fix(lib): default yaml format to yaml_1_2
This commit is contained in:
parent
14077d4916
commit
3ae3055546
1 changed files with 3 additions and 2 deletions
|
|
@ -11,7 +11,8 @@
|
|||
opts,
|
||||
data,
|
||||
}: let
|
||||
format = opts.format or "json";
|
||||
_format = opts.format or "json";
|
||||
format = if _format == "yaml" then "yaml_1_2" else _format;
|
||||
formatOpts = builtins.removeAttrs opts ["format"];
|
||||
formatter = formats.${format} formatOpts;
|
||||
|
||||
|
|
@ -22,7 +23,7 @@
|
|||
lua = "--- Generated by soonix, DO NOT EDIT\n";
|
||||
xml = "<!-- Generated by soonix, DO NOT EDIT -->\n";
|
||||
}.${
|
||||
format
|
||||
_format
|
||||
} or "";
|
||||
in
|
||||
(formatter.generate name data).overrideAttrs (pre: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue