Skip to content

Commit e953824

Browse files
committed
[OCONF-184] Resolve comments
1 parent ae66a55 commit e953824

7 files changed

Lines changed: 3066 additions & 2151 deletions

File tree

coconut/cmd/configuration_history.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
* === This file is part of ALICE O² ===
33
*
4-
* Copyright 2018 CERN and copyright holders of ALICE O².
4+
* Copyright 2019 CERN and copyright holders of ALICE O².
55
* Author: George Raduta <george.raduta@cern.ch>
66
*
77
* This program is free software: you can redistribute it and/or modify
@@ -30,13 +30,13 @@ import (
3030
)
3131

3232
var configurationHistoryCmd = &cobra.Command{
33-
Use: "history [component]",
33+
Use: "history <query>",
3434
Aliases: []string{"h"},
3535
Example: `coconut conf history <component>
3636
coconut conf history <component> <entry>
3737
coconut conf history <component>/<entry>`,
3838
Short: "List all existing entries with timestamps of a specified component in Consul",
39-
Long: `The configuration history command will return all entries with
39+
Long: `The configuration history command returns all entries with
4040
all of their associated timestamps or returns all timestamps for a specified component and entry`,
4141
Run: configuration.WrapCall(configuration.History),
4242
Args: cobra.RangeArgs(0, 3),

coconut/cmd/configuration_list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
* === This file is part of ALICE O² ===
33
*
4-
* Copyright 2018 CERN and copyright holders of ALICE O².
4+
* Copyright 2019 CERN and copyright holders of ALICE O².
55
* Author: George Raduta <george.raduta@cern.ch>
66
*
77
* This program is free software: you can redistribute it and/or modify

coconut/cmd/configuration_show.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
* === This file is part of ALICE O² ===
33
*
4-
* Copyright 2018 CERN and copyright holders of ALICE O².
4+
* Copyright 2019 CERN and copyright holders of ALICE O².
55
* Author: George Raduta <george.raduta@cern.ch>
66
*
77
* This program is free software: you can redistribute it and/or modify

coconut/configuration/configuration.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,8 @@ const (
6868
)
6969

7070
var(
71-
white = color.New(color.FgHiWhite).SprintFunc()
7271
blue = color.New(color.FgHiBlue).SprintFunc()
73-
green = color.New(color.FgHiGreen).SprintFunc()
74-
yellow = color.New(color.FgHiYellow).SprintFunc()
7572
red = color.New(color.FgHiRed).SprintFunc()
76-
grey = color.New(color.FgWhite).SprintFunc()
7773
)
7874

7975
func WrapCall(call ConfigurationCall) RunFunc {
@@ -278,7 +274,7 @@ func History(cfg *configuration.ConsulSource, cmd *cobra.Command, args []string,
278274
var key, component, entry string
279275

280276
if len(args) < 1 || len(args) > 2 {
281-
err = errors.New(fmt.Sprintf(" accepts between 0 and 3 arg(s), but received %d", len(args)))
277+
err = errors.New(fmt.Sprintf("Accepts between 0 and 3 arg(s), but received %d", len(args)))
282278
return err, invalidArgs
283279
}
284280
switch len(args) {

0 commit comments

Comments
 (0)