Skip to content

Commit

Permalink
chore: moving utils under pkg umbrella (#68)
Browse files Browse the repository at this point in the history
* Updating env variables to Prepend crda

* chore: move utils under pkg umbrellia
  • Loading branch information
Deepak Sharma authored Jun 9, 2021
1 parent 734eec0 commit 516f001
Show file tree
Hide file tree
Showing 11 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/rs/zerolog"
"github.com/rs/zerolog/log"

"github.com/fabric8-analytics/cli-tools/utils"
"github.com/fabric8-analytics/cli-tools/pkg/utils"
"github.com/spf13/cobra"
"github.com/spf13/viper"
)
Expand Down
4 changes: 2 additions & 2 deletions pkg/analyses/stackanalyses/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
"encoding/json"
"errors"
"fmt"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"
"io"
"mime/multipart"
"net/http"
Expand All @@ -23,7 +22,8 @@ import (
"github.com/fabric8-analytics/cli-tools/pkg/analyses/pypi"
"github.com/fabric8-analytics/cli-tools/pkg/analyses/summary"
"github.com/fabric8-analytics/cli-tools/pkg/analyses/verbose"
"github.com/fabric8-analytics/cli-tools/utils"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"
"github.com/fabric8-analytics/cli-tools/pkg/utils"
)

// Controller is a control structure.
Expand Down
5 changes: 3 additions & 2 deletions pkg/analyses/summary/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ import (
"context"
"encoding/json"
"fmt"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"
"os"

"github.com/fabric8-analytics/cli-tools/pkg/telemetry"

"github.com/fatih/color"
"github.com/rs/zerolog/log"

"github.com/fabric8-analytics/cli-tools/pkg/analyses/driver"
"github.com/fabric8-analytics/cli-tools/utils"
"github.com/fabric8-analytics/cli-tools/pkg/utils"
)

// ProcessSummary processes summary results, return true if Vul found
Expand Down
5 changes: 3 additions & 2 deletions pkg/analyses/verbose/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ import (
"context"
"encoding/json"
"fmt"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"
"os"
"sort"

"github.com/fabric8-analytics/cli-tools/utils"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"

"github.com/fabric8-analytics/cli-tools/pkg/utils"

"github.com/fatih/color"
"github.com/rs/zerolog/log"
Expand Down
5 changes: 3 additions & 2 deletions pkg/auth/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ import (
"context"
"encoding/json"
"errors"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"
"net/http"

"github.com/fabric8-analytics/cli-tools/utils"
"github.com/fabric8-analytics/cli-tools/pkg/telemetry"

"github.com/fabric8-analytics/cli-tools/pkg/utils"
"github.com/rs/zerolog/log"
)

Expand Down
1 change: 1 addition & 0 deletions pkg/segment/segment.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func (c *Client) Upload(ctx context.Context, action string, duration time.Durati
properties = properties.
Set("success", err == nil).
Set("platform", runtime.GOOS).
Set("version", version.GetCRDAVersion()).
Set("duration", duration.Milliseconds())

if err != nil {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 516f001

Please sign in to comment.