From f82dc010bc6aebe55ce11bb1db79b9a9ca09d525 Mon Sep 17 00:00:00 2001 From: Will Norris Date: Sat, 23 Apr 2016 15:04:09 -0700 Subject: [PATCH] cmd/camtool: output server-config.json string In addition to outputting the JSON config needed for cloudstorage_test, also provide the colon-delimited string needed for server-config.json. Also update URL for Google API Console Fixes #715 Change-Id: I3784ad3442bcf0c99cb738a3beed7b9e5fbcac68 --- cmd/camtool/googinit.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cmd/camtool/googinit.go b/cmd/camtool/googinit.go index 1ff29ac37..5c7f4b473 100644 --- a/cmd/camtool/googinit.go +++ b/cmd/camtool/googinit.go @@ -105,7 +105,8 @@ func (c *googinitCmd) RunCommand(args []string) error { "refresh_token": token.RefreshToken, } enc.Encode(authObj) - fmt.Fprint(cmdmain.Stdout, "\n") + fmt.Fprint(cmdmain.Stdout, "\n\nFor server-config.json, your 'googlecloudstorage' value (update with your bucket name and path):\n\n") + fmt.Fprintf(cmdmain.Stdout, "%s:%s:%s:bucketName[/optional/dir]\n", clientId, clientSecret, token.RefreshToken) return nil } @@ -120,7 +121,7 @@ func prompt(promptText string) string { // Prompt for client id / secret func getClientInfo() (string, string) { fmt.Fprintf(cmdmain.Stdout, "Please provide the client id and client secret \n") - fmt.Fprintf(cmdmain.Stdout, "(You can find these at http://code.google.com/apis/console > your project > API Access)\n") + fmt.Fprintf(cmdmain.Stdout, "(You can find these at https://console.developers.google.com/apis/credentials)\n") var ( clientId string clientSecret string