Skip to content

Commit 461f94f

Browse files
David Cariellorabbah
authored andcommitted
add OS and CPU architecture to user agent header (#344)
1 parent 42307de commit 461f94f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

commands/commands.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ import (
2121
"errors"
2222
"net/http"
2323
"os"
24+
"runtime"
2425

2526
"github.com/apache/incubator-openwhisk-cli/wski18n"
2627
"github.com/apache/incubator-openwhisk-client-go/whisk"
@@ -64,7 +65,7 @@ func SetupClientConfig(cmd *cobra.Command, args []string) error {
6465
Version: Properties.APIVersion,
6566
Insecure: Flags.Global.Insecure,
6667
Host: Properties.APIHost,
67-
UserAgent: UserAgent + "/1.0 (" + Properties.CLIVersion + ")",
68+
UserAgent: UserAgent + "/1.0 (" + Properties.CLIVersion + ") " + runtime.GOOS + " " + runtime.GOARCH,
6869
AdditionalHeaders: AdditionalHeaders,
6970
}
7071

0 commit comments

Comments
 (0)