diff --git a/Makefile b/Makefile index c0d979c..748e6d2 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ GOBIN ?= $(shell go env GOPATH)/bin PKG = github.com/dotzero/git-profile BIN := git-profile -VERSION := 1.4.0 +VERSION := 1.5.0 HASH := $(shell git rev-parse --short HEAD) DATE := $(shell date +%FT%T%z) diff --git a/cmd/current.go b/cmd/current.go index 84f2b8b..4709e32 100644 --- a/cmd/current.go +++ b/cmd/current.go @@ -25,11 +25,11 @@ func Current(cfg storage, v vcs) *cobra.Command { res, err := v.Get(currentProfileKey) if len(res) == 0 || err != nil { - cmd.Print(defaultProfileName) + cmd.Printf("%s\n", defaultProfileName) os.Exit(0) } - cmd.Printf("%s", res) + cmd.Printf("%s\n", res) }, } } diff --git a/cmd/root.go b/cmd/root.go index d8d6e0c..7bac783 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -46,7 +46,7 @@ func New() *Cmd { CommitHash: "Unknown", CompileDate: "Unknown", config: config.New(), - git: &git.Git{}, + git: git.New(), } } diff --git a/cmd/use.go b/cmd/use.go index 5b748ac..464e147 100644 --- a/cmd/use.go +++ b/cmd/use.go @@ -43,7 +43,7 @@ func Use(cfg storage, v vcs) *cobra.Command { } } - cmd.Printf("Successfully applied `%s` profile to current git repository.", profile) + cmd.Printf("Successfully applied `%s` profile to current git repository.\n", profile) }, } }