Skip to content

Commit

Permalink
less header lines
Browse files Browse the repository at this point in the history
  • Loading branch information
corylanou committed Mar 12, 2015
1 parent 5ce7307 commit b0be24b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions cmd/influx/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,18 +355,16 @@ func (c *CommandLine) formatResults(result client.Result, separator string) []st
// If we are column format, we break out the name/tag to seperate lines
if c.Format == "column" {
if row.Name != "" {
rows = append(rows, row.Name)
n := fmt.Sprintf("name: %s", row.Name)
rows = append(rows, n)
if len(tags) == 0 {
l := strings.Repeat("-", len(row.Name))
l := strings.Repeat("-", len(n))
rows = append(rows, l)
}
}
if len(tags) > 0 {
t := fmt.Sprintf("tags: %s", (strings.Join(tags, ", ")))
l := strings.Repeat("-", len(t))
rows = append(rows, l)
rows = append(rows, t)
rows = append(rows, l)
}
}

Expand Down

0 comments on commit b0be24b

Please sign in to comment.