Skip to content

Commit

Permalink
Release v1.15.2
Browse files Browse the repository at this point in the history
- Allow empty key names in JSON output. ([GitHub #57](#57))
- Fix a bug of the "--allow-uneven-fields" option. ([GitHub #59](#59))
  • Loading branch information
mithrandie committed Jun 13, 2021
2 parents f99f2d9 + c07eb5f commit 9f3672d
Show file tree
Hide file tree
Showing 9 changed files with 65 additions and 12 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Change Log

## Version 1.15.2

Released on June 13, 2021

- Allow empty key names in JSON output. ([GitHub #57](https://github.com/mithrandie/csvq/issues/57))
- Fix a bug of the "--allow-uneven-fields" option. ([GitHub #59](https://github.com/mithrandie/csvq/issues/59))

## Version 1.15.1

Released on May 5, 2021
Expand Down
7 changes: 7 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ title: Change Log - csvq

# Change Log

## Version 1.15.2

Released on June 13, 2021

- Allow empty key names in JSON output. ([GitHub #57](https://github.com/mithrandie/csvq/issues/57))
- Fix a bug of the "--allow-uneven-fields" option. ([GitHub #59](https://github.com/mithrandie/csvq/issues/59))

## Version 1.15.1

Released on May 5, 2021
Expand Down
6 changes: 3 additions & 3 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ In the multiple operations, you can use variables, cursors, temporary tables, an

## Latest Release

Version 1.15.1
: Released on May 5, 2021
Version 1.15.2
: Released on June 13, 2021

<a class="waves-effect waves-light btn" href="https://github.com/mithrandie/csvq/releases/tag/v1.15.1">
<a class="waves-effect waves-light btn" href="https://github.com/mithrandie/csvq/releases/tag/v1.15.2">
<i class="material-icons left">file_download</i>download
</a>

Expand Down
4 changes: 2 additions & 2 deletions docs/sitemap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
<url>
<loc>https://mithrandie.github.io/csvq/</loc>
<lastmod>2021-05-05T00:06:28+00:00</lastmod>
<lastmod>2021-06-13T14:02:24+00:00</lastmod>
</url>
<url>
<loc>https://mithrandie.github.io/csvq/reference.html</loc>
Expand Down Expand Up @@ -178,7 +178,7 @@
</url>
<url>
<loc>https://mithrandie.github.io/csvq/changelog.html</loc>
<lastmod>2021-05-05T00:06:28+00:00</lastmod>
<lastmod>2021-06-13T14:02:24+00:00</lastmod>
</url>
<url>
<loc>https://mithrandie.github.io/csvq/license.html</loc>
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/mithrandie/csvq
require (
github.com/mitchellh/go-homedir v1.0.0
github.com/mithrandie/go-file/v2 v2.0.2
github.com/mithrandie/go-text v1.4.0
github.com/mithrandie/go-text v1.4.1
github.com/mithrandie/readline-csvq v1.1.1
github.com/mithrandie/ternary v1.1.0
github.com/urfave/cli v1.20.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ github.com/mitchellh/go-homedir v1.0.0 h1:vKb8ShqSby24Yrqr/yDYkuFz8d0WUjys40rvnG
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
github.com/mithrandie/go-file/v2 v2.0.2 h1:3/yzItlTssDX9wOZrj9MtRyXbr52OZURmXFMuvpJ6Fg=
github.com/mithrandie/go-file/v2 v2.0.2/go.mod h1:98a9loPjYr7ffsfwMDdJ7iH/dO8EXAca8XiI6SZpPV8=
github.com/mithrandie/go-text v1.4.0 h1:hK2i8ydiM3Uc5UqaY/aNz9ztdlNT8RvBJnJLIOX+tUM=
github.com/mithrandie/go-text v1.4.0/go.mod h1:Ivtyn3cuJYAs2UpihWmnY1KAixmLonELJ454EOZGzDg=
github.com/mithrandie/go-text v1.4.1 h1:tLIMamsVRYKsDTIDu7hZifOA4gtwSUln1zrZ9GM0eTU=
github.com/mithrandie/go-text v1.4.1/go.mod h1:Ivtyn3cuJYAs2UpihWmnY1KAixmLonELJ454EOZGzDg=
github.com/mithrandie/readline-csvq v1.1.1 h1:kp9W5WPUAB+NOgW5axPdu8mZe1M9CP/D1xpabj39JVY=
github.com/mithrandie/readline-csvq v1.1.1/go.mod h1:eOJt0j6UI9lhwM/KP+v40ugarhXsnPIXStvkfIaq79E=
github.com/mithrandie/ternary v1.1.0 h1:BlN8EoTsIYjhuWkfXHrh7+G+/Y0VvvWGVVldyjNH2VU=
Expand Down
3 changes: 0 additions & 3 deletions lib/json/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,6 @@ func (pmap PathMap) load(key string) (PathExpression, bool) {

func (pmap PathMap) Parse(s string) (PathExpression, error) {
s = strings.TrimSpace(s)
if len(s) < 1 {
return nil, nil
}

if e, ok := pmap.load(s); ok {
return e, nil
Expand Down
42 changes: 42 additions & 0 deletions lib/json/conversion_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,48 @@ var convertTableValueToJsonStructureTests = []struct {
},
},
},
{
Fields: []string{
"column1",
"",
},
Rows: [][]value.Primary{
{
value.NewString("a"),
value.NewInteger(1),
},
{
value.NewString("b"),
value.NewFloat(0.2),
},
},
Expect: json.Array{
json.Object{
Members: []json.ObjectMember{
{
Key: "column1",
Value: json.String("a"),
},
{
Key: "",
Value: json.Integer(1),
},
},
},
json.Object{
Members: []json.ObjectMember{
{
Key: "column1",
Value: json.String("b"),
},
{
Key: "",
Value: json.Float(0.2),
},
},
},
},
},
{
Fields: []string{
"column1",
Expand Down
2 changes: 1 addition & 1 deletion lib/query/version.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
package query

var Version = "v1.15.1"
var Version = "v1.15.2"

0 comments on commit 9f3672d

Please sign in to comment.