From 160c3dd5918cff54871d5a44f876269577c8668e Mon Sep 17 00:00:00 2001 From: amalej Date: Sun, 21 Jan 2024 01:30:07 +0800 Subject: [PATCH 1/3] fix: typos in samples --- samples/jwt.js | 2 +- samples/keyfile.js | 2 +- samples/scripts/externalclient-setup.js | 2 +- samples/test/externalclient.test.js | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/samples/jwt.js b/samples/jwt.js index 3110c8f9..7776435a 100644 --- a/samples/jwt.js +++ b/samples/jwt.js @@ -27,7 +27,7 @@ const {JWT} = require('google-auth-library'); const fs = require('fs'); async function main( - // Full path to the sevice account credential + // Full path to the service account credential keyFile = process.env.GOOGLE_APPLICATION_CREDENTIALS ) { const keys = JSON.parse(fs.readFileSync(keyFile, 'utf8')); diff --git a/samples/keyfile.js b/samples/keyfile.js index 5915f518..b8a33640 100644 --- a/samples/keyfile.js +++ b/samples/keyfile.js @@ -22,7 +22,7 @@ const {GoogleAuth} = require('google-auth-library'); * Acquire a client, and make a request to an API that's enabled by default. */ async function main( - // Full path to the sevice account credential + // Full path to the service account credential keyFile = process.env.GOOGLE_APPLICATION_CREDENTIALS ) { const auth = new GoogleAuth({ diff --git a/samples/scripts/externalclient-setup.js b/samples/scripts/externalclient-setup.js index 21e75954..caf24bd7 100755 --- a/samples/scripts/externalclient-setup.js +++ b/samples/scripts/externalclient-setup.js @@ -165,7 +165,7 @@ async function main(config) { const awsAudience = `//iam.googleapis.com/${poolResourcePath}/providers/${awsProviderId}`; // Allow service account impersonation. - // Get the existing IAM policity bindings on the current service account. + // Get the existing IAM policy bindings on the current service account. response = await iam.projects.serviceAccounts.getIamPolicy({ resource: `projects/${projectId}/serviceAccounts/${clientEmail}`, }); diff --git a/samples/test/externalclient.test.js b/samples/test/externalclient.test.js index 6efdc3f3..b3e231c3 100644 --- a/samples/test/externalclient.test.js +++ b/samples/test/externalclient.test.js @@ -50,7 +50,7 @@ // AWS provider tests for AWS credentials // ------------------------------------- // The test suite will also run tests for AWS credentials. This works as -// follows. (Note prequisite setup is needed. This is documented in +// follows. (Note prerequisite setup is needed. This is documented in // externalclient-setup.js). // - iamcredentials:generateIdToken is used to generate a Google ID token using // the service account access token. The service account client_id is used as From 92c621b73d7f50f8decd3b8c5c70b02e1875d85b Mon Sep 17 00:00:00 2001 From: Daniel Bankhead Date: Tue, 23 Jan 2024 13:40:05 -0800 Subject: [PATCH 2/3] chore: Fix copyright --- samples/jwt.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/samples/jwt.js b/samples/jwt.js index 7776435a..62b9cccd 100644 --- a/samples/jwt.js +++ b/samples/jwt.js @@ -1,9 +1,10 @@ -// Copyright 2017, Google, Inc. +// Copyright 2017 Google LLC +// // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // -// http://www.apache.org/licenses/LICENSE-2.0 +// http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, From ba7a2bbddcb1c99dd7bcea9ccaab10e1853a5602 Mon Sep 17 00:00:00 2001 From: Daniel Bankhead Date: Tue, 23 Jan 2024 13:40:59 -0800 Subject: [PATCH 3/3] chore: Fix copyright --- samples/keyfile.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/samples/keyfile.js b/samples/keyfile.js index b8a33640..3018d843 100644 --- a/samples/keyfile.js +++ b/samples/keyfile.js @@ -1,9 +1,10 @@ -// Copyright 2018, Google, LLC. +// Copyright 2018 Google LLC +// // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // -// http://www.apache.org/licenses/LICENSE-2.0 +// http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS,