Config: Make json.array default to "on"

- This makes the default "export" output work out of the box with most
  JSON parsing libraries.
This commit is contained in:
Wilhelm Schuermann
2015-07-03 23:38:14 +02:00
parent e516f2bf65
commit c1a0370daa
6 changed files with 14 additions and 7 deletions

View File

@@ -48,7 +48,7 @@ class TestExportCommand(TestCase):
self.t(('add', 'test'))
def export(self, identifier):
return json.loads(self.t((str(identifier), 'export'))[1].strip())
return json.loads(self.t((str(identifier), 'rc.json.array=off', 'export'))[1].strip())
def assertType(self, value, type):
self.assertEqual(isinstance(value, type), True)

View File

@@ -44,7 +44,8 @@ $source_dir =~ s{[^/]+$}{..};
if (open my $fh, '>', $rc)
{
print $fh "data.location=.\n",
"verbose=no\n";
"verbose=no\n",
"json.array=off";
close $fh;
}

View File

@@ -44,7 +44,8 @@ if (open my $fh, '>', $rc)
"verbose=off\n",
"confirmation=no\n",
"defaultwidth=100\n",
"dateformat=m/d/Y\n";
"dateformat=m/d/Y\n",
"json.array=off";
close $fh;
}