You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by cs...@apache.org on 2017/09/18 14:55:29 UTC
[incubator-openwhisk-cli] 01/16: CLI User Agent Header (#2591)
This is an automated email from the ASF dual-hosted git repository.
csantanapr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-cli.git
commit 0eafc9b09cb1b8bcb0311513989dd768fe95aef1
Author: David Cariello <dr...@us.ibm.com>
AuthorDate: Thu Sep 7 22:33:17 2017 -0500
CLI User Agent Header (#2591)
---
commands/commands.go | 2 ++
1 file changed, 2 insertions(+)
diff --git a/commands/commands.go b/commands/commands.go
index 7bd00b0..d15eae5 100644
--- a/commands/commands.go
+++ b/commands/commands.go
@@ -30,6 +30,7 @@ import (
var client *whisk.Client
const DefaultOpenWhiskApiPath string = "/api"
+var UserAgent string = "OpenWhisk-CLI"
func setupClientConfig(cmd *cobra.Command, args []string) (error){
baseURL, err := GetURLBase(Properties.APIHost, DefaultOpenWhiskApiPath)
@@ -60,6 +61,7 @@ func setupClientConfig(cmd *cobra.Command, args []string) (error){
Version: Properties.APIVersion,
Insecure: Flags.Global.Insecure,
Host: Properties.APIHost,
+ UserAgent: UserAgent + "/1.0 (" + Properties.CLIVersion + ")",
}
// Setup client
--
To stop receiving notification emails like this one, please contact
"commits@openwhisk.apache.org" <co...@openwhisk.apache.org>.