Skip to content

Missing information in codelabs page 2 for windows machines #32

@LukeRenton

Description

@LukeRenton

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions