Skip to content

Commit

Permalink
chore: build dist (#409)
Browse files Browse the repository at this point in the history
  • Loading branch information
google-github-actions-bot committed Dec 1, 2021
1 parent de988cc commit 94faef2
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 3 deletions.
21 changes: 18 additions & 3 deletions dist/main/index.js
Expand Up @@ -10660,6 +10660,21 @@ exports.debug = debug; // for test
/***/ (function(__unusedmodule, exports, __webpack_require__) {

"use strict";
/*
* Copyright 2021 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
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
Expand Down Expand Up @@ -14432,16 +14447,16 @@ function run() {
// because GITHUB_WORKSPACE is not automatically cleaned up on
// self-hosted runners. To mitigate this issue, this action defines a
// post step to remove any created credentials.
const runnerTempDir = process.env.GITHUB_WORKSPACE;
if (!runnerTempDir) {
const githubWorkspace = process.env.GITHUB_WORKSPACE;
if (!githubWorkspace) {
throw new Error('$GITHUB_WORKSPACE is not set');
}
// Generate a random filename to store the credential. 12 bytes is 24
// characters in hex. It's not the ideal entropy, but we have to be under
// the 255 character limit for Windows filenames (which includes their
// entire leading path).
const uniqueName = crypto_1.default.randomBytes(12).toString('hex');
credsPath = path_1.default.join(runnerTempDir, uniqueName);
credsPath = path_1.default.join(githubWorkspace, uniqueName);
}
const serviceAccountKeyObj = (0, setup_cloud_sdk_1.parseServiceAccountKey)(serviceAccountKey);
yield (0, utils_1.writeSecureFile)(credsPath, JSON.stringify(serviceAccountKeyObj, null, 2));
Expand Down
30 changes: 30 additions & 0 deletions dist/post/index.js
Expand Up @@ -435,6 +435,21 @@ exports.debug = debug; // for test
/***/ (function(__unusedmodule, exports, __webpack_require__) {

"use strict";
/*
* Copyright 2021 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
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
Expand Down Expand Up @@ -1681,6 +1696,21 @@ module.exports = require("fs");
/***/ (function(__unusedmodule, exports, __webpack_require__) {

"use strict";
/*
* Copyright 2021 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
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
Expand Down

0 comments on commit 94faef2

Please sign in to comment.