From ee8b949d38ee90fb371c776f0725fc8629908539 Mon Sep 17 00:00:00 2001 From: Christopher Harrison Date: Mon, 2 Dec 2024 09:58:50 +0000 Subject: [PATCH] TOML: Hardline after table-less pairs --- topiary-cli/tests/samples/expected/toml.toml | 5 +++++ topiary-cli/tests/samples/input/toml.toml | 4 ++++ topiary-queries/queries/toml.scm | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/topiary-cli/tests/samples/expected/toml.toml b/topiary-cli/tests/samples/expected/toml.toml index d23e03ff..5fe7a547 100644 --- a/topiary-cli/tests/samples/expected/toml.toml +++ b/topiary-cli/tests/samples/expected/toml.toml @@ -1,3 +1,8 @@ +# Table-less pairs (#798) +foo = "bar" +baz = 'quux' +abc = 123 + [package] name = "topiary" diff --git a/topiary-cli/tests/samples/input/toml.toml b/topiary-cli/tests/samples/input/toml.toml index 4668dccd..8b139eca 100644 --- a/topiary-cli/tests/samples/input/toml.toml +++ b/topiary-cli/tests/samples/input/toml.toml @@ -1,3 +1,7 @@ +# Table-less pairs (#798) +foo = "bar" +baz = 'quux' +abc = 123 [package] diff --git a/topiary-queries/queries/toml.scm b/topiary-queries/queries/toml.scm index 6081dfd3..945472f9 100644 --- a/topiary-queries/queries/toml.scm +++ b/topiary-queries/queries/toml.scm @@ -19,6 +19,10 @@ (comment) ] @append_hardline +(document + (pair) @append_hardline +) + (table (pair) @append_hardline )