Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing information in codelabs page 2 for windows machines #32

Open
LukeRenton opened this issue Apr 16, 2024 · 0 comments
Open

Missing information in codelabs page 2 for windows machines #32

LukeRenton opened this issue Apr 16, 2024 · 0 comments

Comments

@LukeRenton
Copy link

I believe there to be a lack of information in page 2 (https://codelabs.developers.google.com/add-to-wallet-web#1) of the code labs under the title Create a service key account when it comes to verifying if the environment variable GOOGLE_APPLICATION_CREDENTIALS is set on windows machines.

It says: "Verify the environment variable is set in a new terminal (MacOS/Linux) or command-line (Windows) session (you may need to start a new session if you have one open already)"
echo $GOOGLE_APPLICATION_CREDENTIALS

On windows this command is incorrect for properly displaying the contents for the environment variable GOOGLE_APPLICATION_CREDENTIALS

As seen here (in PowerShell run as admin):

> $env:GOOGLE_APPLICATION_CREDENTIALS="C:\Users\user\Downloads\file-name-goes-here.json"

---- new terminal session

> echo $GOOGLE_APPLICATION_CREDENTIALS
> (blank)

The correct command would be as follows for Windows PowerShell:

> $env:GOOGLE_APPLICATION_CREDENTIALS="C:\Users\user\Downloads\file-name-goes-here.json"

--- (new terminal session)

> echo $env:GOOGLE_APPLICATION_CREDENTIALS`
> C:\Users\user\Downloads\file-name-goes-here.json`

As required.

The display command for Command Prompt is also different:

> echo %GOOGLE_APPLICATION_CREDENTIALS%
> C:\Users\user\Downloads\file-name-goes-here.json

I know this is something small, but I think it will help future developers (on windows) follow along better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant