|
|
@ -1376,14 +1376,27 @@ module.exports = windowsRelease;
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
var result = {};
|
|
|
|
var result = {};
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
result["default"] = mod;
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
return result;
|
|
|
|
return result;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.getServerUrl = exports.getFetchUrl = void 0;
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const url_1 = __webpack_require__(835);
|
|
|
|
const url_1 = __webpack_require__(835);
|
|
|
|
function getFetchUrl(settings) {
|
|
|
|
function getFetchUrl(settings) {
|
|
|
@ -2806,14 +2819,27 @@ function paginatePlugin(octokit) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
var result = {};
|
|
|
|
var result = {};
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
result["default"] = mod;
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
return result;
|
|
|
|
return result;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.setSshKnownHostsPath = exports.setSshKeyPath = exports.setRepositoryPath = exports.SshKnownHostsPath = exports.SshKeyPath = exports.RepositoryPath = exports.IsPost = void 0;
|
|
|
|
const coreCommand = __importStar(__webpack_require__(431));
|
|
|
|
const coreCommand = __importStar(__webpack_require__(431));
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Indicates whether the POST action is running
|
|
|
|
* Indicates whether the POST action is running
|
|
|
@ -3318,6 +3344,25 @@ function checkMode (stat, options) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -3327,13 +3372,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const coreCommand = __importStar(__webpack_require__(431));
|
|
|
|
const coreCommand = __importStar(__webpack_require__(431));
|
|
|
@ -3342,6 +3380,7 @@ const inputHelper = __importStar(__webpack_require__(821));
|
|
|
|
const path = __importStar(__webpack_require__(622));
|
|
|
|
const path = __importStar(__webpack_require__(622));
|
|
|
|
const stateHelper = __importStar(__webpack_require__(153));
|
|
|
|
const stateHelper = __importStar(__webpack_require__(153));
|
|
|
|
function run() {
|
|
|
|
function run() {
|
|
|
|
|
|
|
|
var _a, _b;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
const sourceSettings = inputHelper.getInputs();
|
|
|
|
const sourceSettings = inputHelper.getInputs();
|
|
|
@ -3357,17 +3396,18 @@ function run() {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
core.setFailed(error.message);
|
|
|
|
core.setFailed(`${(_b = (_a = error) === null || _a === void 0 ? void 0 : _a.message) !== null && _b !== void 0 ? _b : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
function cleanup() {
|
|
|
|
function cleanup() {
|
|
|
|
|
|
|
|
var _a, _b;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
yield gitSourceProvider.cleanup(stateHelper.RepositoryPath);
|
|
|
|
yield gitSourceProvider.cleanup(stateHelper.RepositoryPath);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
core.warning(error.message);
|
|
|
|
core.warning(`${(_b = (_a = error) === null || _a === void 0 ? void 0 : _a.message) !== null && _b !== void 0 ? _b : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -3425,6 +3465,25 @@ module.exports = {"name":"@octokit/rest","version":"16.43.1","publishConfig":{"a
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -3434,14 +3493,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.checkCommitInfo = exports.testRef = exports.getRefSpec = exports.getRefSpecForAllHistory = exports.getCheckoutInfo = exports.tagsRefSpec = void 0;
|
|
|
|
const url_1 = __webpack_require__(835);
|
|
|
|
const url_1 = __webpack_require__(835);
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const github = __importStar(__webpack_require__(469));
|
|
|
|
const github = __importStar(__webpack_require__(469));
|
|
|
@ -3595,6 +3648,7 @@ function testRef(git, ref, commit) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
exports.testRef = testRef;
|
|
|
|
exports.testRef = testRef;
|
|
|
|
function checkCommitInfo(token, commitInfo, repositoryOwner, repositoryName, ref, commit) {
|
|
|
|
function checkCommitInfo(token, commitInfo, repositoryOwner, repositoryName, ref, commit) {
|
|
|
|
|
|
|
|
var _a, _b;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
// GHES?
|
|
|
|
// GHES?
|
|
|
@ -3650,7 +3704,7 @@ function checkCommitInfo(token, commitInfo, repositoryOwner, repositoryName, ref
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
core.debug(`Error when validating commit info: ${err.stack}`);
|
|
|
|
core.debug(`Error when validating commit info: ${(_b = (_a = err) === null || _a === void 0 ? void 0 : _a.stack) !== null && _b !== void 0 ? _b : err}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -5434,6 +5488,25 @@ function coerce (version) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -5443,17 +5516,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
|
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.createAuthHelper = void 0;
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const exec = __importStar(__webpack_require__(986));
|
|
|
|
const exec = __importStar(__webpack_require__(986));
|
|
|
@ -5500,11 +5567,12 @@ class GitAuthHelper {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
configureGlobalAuth() {
|
|
|
|
configureGlobalAuth() {
|
|
|
|
|
|
|
|
var _a;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
// Create a temp home directory
|
|
|
|
// Create a temp home directory
|
|
|
|
const runnerTemp = process.env['RUNNER_TEMP'] || '';
|
|
|
|
const runnerTemp = process.env['RUNNER_TEMP'] || '';
|
|
|
|
assert.ok(runnerTemp, 'RUNNER_TEMP is not defined');
|
|
|
|
assert.ok(runnerTemp, 'RUNNER_TEMP is not defined');
|
|
|
|
const uniqueId = v4_1.default();
|
|
|
|
const uniqueId = (0, v4_1.default)();
|
|
|
|
this.temporaryHomePath = path.join(runnerTemp, uniqueId);
|
|
|
|
this.temporaryHomePath = path.join(runnerTemp, uniqueId);
|
|
|
|
yield fs.promises.mkdir(this.temporaryHomePath, { recursive: true });
|
|
|
|
yield fs.promises.mkdir(this.temporaryHomePath, { recursive: true });
|
|
|
|
// Copy the global git config
|
|
|
|
// Copy the global git config
|
|
|
@ -5516,7 +5584,7 @@ class GitAuthHelper {
|
|
|
|
configExists = true;
|
|
|
|
configExists = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
if (err.code !== 'ENOENT') {
|
|
|
|
if (((_a = err) === null || _a === void 0 ? void 0 : _a.code) !== 'ENOENT') {
|
|
|
|
throw err;
|
|
|
|
throw err;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -5587,6 +5655,7 @@ class GitAuthHelper {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
configureSsh() {
|
|
|
|
configureSsh() {
|
|
|
|
|
|
|
|
var _a;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
if (!this.settings.sshKey) {
|
|
|
|
if (!this.settings.sshKey) {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
@ -5594,7 +5663,7 @@ class GitAuthHelper {
|
|
|
|
// Write key
|
|
|
|
// Write key
|
|
|
|
const runnerTemp = process.env['RUNNER_TEMP'] || '';
|
|
|
|
const runnerTemp = process.env['RUNNER_TEMP'] || '';
|
|
|
|
assert.ok(runnerTemp, 'RUNNER_TEMP is not defined');
|
|
|
|
assert.ok(runnerTemp, 'RUNNER_TEMP is not defined');
|
|
|
|
const uniqueId = v4_1.default();
|
|
|
|
const uniqueId = (0, v4_1.default)();
|
|
|
|
this.sshKeyPath = path.join(runnerTemp, uniqueId);
|
|
|
|
this.sshKeyPath = path.join(runnerTemp, uniqueId);
|
|
|
|
stateHelper.setSshKeyPath(this.sshKeyPath);
|
|
|
|
stateHelper.setSshKeyPath(this.sshKeyPath);
|
|
|
|
yield fs.promises.mkdir(runnerTemp, { recursive: true });
|
|
|
|
yield fs.promises.mkdir(runnerTemp, { recursive: true });
|
|
|
@ -5612,7 +5681,7 @@ class GitAuthHelper {
|
|
|
|
userKnownHosts = (yield fs.promises.readFile(userKnownHostsPath)).toString();
|
|
|
|
userKnownHosts = (yield fs.promises.readFile(userKnownHostsPath)).toString();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
if (err.code !== 'ENOENT') {
|
|
|
|
if (((_a = err) === null || _a === void 0 ? void 0 : _a.code) !== 'ENOENT') {
|
|
|
|
throw err;
|
|
|
|
throw err;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -5673,6 +5742,7 @@ class GitAuthHelper {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
removeSsh() {
|
|
|
|
removeSsh() {
|
|
|
|
|
|
|
|
var _a, _b;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
// SSH key
|
|
|
|
// SSH key
|
|
|
|
const keyPath = this.sshKeyPath || stateHelper.SshKeyPath;
|
|
|
|
const keyPath = this.sshKeyPath || stateHelper.SshKeyPath;
|
|
|
@ -5681,7 +5751,7 @@ class GitAuthHelper {
|
|
|
|
yield io.rmRF(keyPath);
|
|
|
|
yield io.rmRF(keyPath);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
core.debug(err.message);
|
|
|
|
core.debug(`${(_b = (_a = err) === null || _a === void 0 ? void 0 : _a.message) !== null && _b !== void 0 ? _b : err}`);
|
|
|
|
core.warning(`Failed to remove SSH key '${keyPath}'`);
|
|
|
|
core.warning(`Failed to remove SSH key '${keyPath}'`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -5691,7 +5761,7 @@ class GitAuthHelper {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
yield io.rmRF(knownHostsPath);
|
|
|
|
yield io.rmRF(knownHostsPath);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (_a) {
|
|
|
|
catch (_c) {
|
|
|
|
// Intentionally empty
|
|
|
|
// Intentionally empty
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -5728,6 +5798,25 @@ class GitAuthHelper {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -5737,14 +5826,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.createCommandManager = exports.MinimumGitVersion = void 0;
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const exec = __importStar(__webpack_require__(986));
|
|
|
|
const exec = __importStar(__webpack_require__(986));
|
|
|
|
const fshelper = __importStar(__webpack_require__(618));
|
|
|
|
const fshelper = __importStar(__webpack_require__(618));
|
|
|
@ -6173,6 +6256,25 @@ class GitOutput {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -6182,14 +6284,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.cleanup = exports.getSource = void 0;
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const fsHelper = __importStar(__webpack_require__(618));
|
|
|
|
const fsHelper = __importStar(__webpack_require__(618));
|
|
|
|
const gitAuthHelper = __importStar(__webpack_require__(287));
|
|
|
|
const gitAuthHelper = __importStar(__webpack_require__(287));
|
|
|
@ -7632,6 +7728,25 @@ function escapeProperty(s) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -7641,14 +7756,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.prepareExistingDirectory = void 0;
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
@ -7656,6 +7765,7 @@ const fsHelper = __importStar(__webpack_require__(618));
|
|
|
|
const io = __importStar(__webpack_require__(1));
|
|
|
|
const io = __importStar(__webpack_require__(1));
|
|
|
|
const path = __importStar(__webpack_require__(622));
|
|
|
|
const path = __importStar(__webpack_require__(622));
|
|
|
|
function prepareExistingDirectory(git, repositoryPath, repositoryUrl, clean, ref) {
|
|
|
|
function prepareExistingDirectory(git, repositoryPath, repositoryUrl, clean, ref) {
|
|
|
|
|
|
|
|
var _a, _b;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
assert.ok(repositoryPath, 'Expected repositoryPath to be defined');
|
|
|
|
assert.ok(repositoryPath, 'Expected repositoryPath to be defined');
|
|
|
|
assert.ok(repositoryUrl, 'Expected repositoryUrl to be defined');
|
|
|
|
assert.ok(repositoryUrl, 'Expected repositoryUrl to be defined');
|
|
|
@ -7681,7 +7791,7 @@ function prepareExistingDirectory(git, repositoryPath, repositoryUrl, clean, ref
|
|
|
|
yield io.rmRF(lockPath);
|
|
|
|
yield io.rmRF(lockPath);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
core.debug(`Unable to delete '${lockPath}'. ${error.message}`);
|
|
|
|
core.debug(`Unable to delete '${lockPath}'. ${(_b = (_a = error) === null || _a === void 0 ? void 0 : _a.message) !== null && _b !== void 0 ? _b : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
try {
|
|
|
@ -9611,6 +9721,25 @@ exports.RequestError = RequestError;
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -9620,17 +9749,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
|
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.getDefaultBranch = exports.downloadRepository = void 0;
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const assert = __importStar(__webpack_require__(357));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
@ -9655,7 +9778,7 @@ function downloadRepository(authToken, owner, repo, ref, commit, repositoryPath)
|
|
|
|
}));
|
|
|
|
}));
|
|
|
|
// Write archive to disk
|
|
|
|
// Write archive to disk
|
|
|
|
core.info('Writing archive to disk');
|
|
|
|
core.info('Writing archive to disk');
|
|
|
|
const uniqueId = v4_1.default();
|
|
|
|
const uniqueId = (0, v4_1.default)();
|
|
|
|
const archivePath = path.join(repositoryPath, `${uniqueId}.tar.gz`);
|
|
|
|
const archivePath = path.join(repositoryPath, `${uniqueId}.tar.gz`);
|
|
|
|
yield fs.promises.writeFile(archivePath, archiveData);
|
|
|
|
yield fs.promises.writeFile(archivePath, archiveData);
|
|
|
|
archiveData = Buffer.from(''); // Free memory
|
|
|
|
archiveData = Buffer.from(''); // Free memory
|
|
|
@ -9698,6 +9821,7 @@ exports.downloadRepository = downloadRepository;
|
|
|
|
function getDefaultBranch(authToken, owner, repo) {
|
|
|
|
function getDefaultBranch(authToken, owner, repo) {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return yield retryHelper.execute(() => __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return yield retryHelper.execute(() => __awaiter(this, void 0, void 0, function* () {
|
|
|
|
|
|
|
|
var _a;
|
|
|
|
core.info('Retrieving the default branch name');
|
|
|
|
core.info('Retrieving the default branch name');
|
|
|
|
const octokit = new github.GitHub(authToken);
|
|
|
|
const octokit = new github.GitHub(authToken);
|
|
|
|
let result;
|
|
|
|
let result;
|
|
|
@ -9709,7 +9833,8 @@ function getDefaultBranch(authToken, owner, repo) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
// Handle .wiki repo
|
|
|
|
// Handle .wiki repo
|
|
|
|
if (err['status'] === 404 && repo.toUpperCase().endsWith('.WIKI')) {
|
|
|
|
if (((_a = err) === null || _a === void 0 ? void 0 : _a.status) === 404 &&
|
|
|
|
|
|
|
|
repo.toUpperCase().endsWith('.WIKI')) {
|
|
|
|
result = 'master';
|
|
|
|
result = 'master';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// Otherwise error
|
|
|
|
// Otherwise error
|
|
|
@ -10399,6 +10524,7 @@ module.exports.Collection = Hook.Collection
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.escape = void 0;
|
|
|
|
function escape(value) {
|
|
|
|
function escape(value) {
|
|
|
|
return value.replace(/[^a-zA-Z0-9_]/g, x => {
|
|
|
|
return value.replace(/[^a-zA-Z0-9_]/g, x => {
|
|
|
|
return `\\${x}`;
|
|
|
|
return `\\${x}`;
|
|
|
@ -11455,6 +11581,7 @@ function hasPreviousPage (link) {
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.GitVersion = void 0;
|
|
|
|
class GitVersion {
|
|
|
|
class GitVersion {
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Used for comparing the version of git and git-lfs against the minimum required version
|
|
|
|
* Used for comparing the version of git and git-lfs against the minimum required version
|
|
|
@ -11732,6 +11859,25 @@ function getPageLinks (link) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
|
@ -11741,14 +11887,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
|
|
|
|
var result = {};
|
|
|
|
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
|
|
|
|
result["default"] = mod;
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.execute = exports.RetryHelper = void 0;
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const defaultMaxAttempts = 3;
|
|
|
|
const defaultMaxAttempts = 3;
|
|
|
|
const defaultMinSeconds = 10;
|
|
|
|
const defaultMinSeconds = 10;
|
|
|
@ -11763,6 +11903,7 @@ class RetryHelper {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
execute(action) {
|
|
|
|
execute(action) {
|
|
|
|
|
|
|
|
var _a;
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
let attempt = 1;
|
|
|
|
let attempt = 1;
|
|
|
|
while (attempt < this.maxAttempts) {
|
|
|
|
while (attempt < this.maxAttempts) {
|
|
|
@ -11771,7 +11912,7 @@ class RetryHelper {
|
|
|
|
return yield action();
|
|
|
|
return yield action();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
catch (err) {
|
|
|
|
core.info(err.message);
|
|
|
|
core.info((_a = err) === null || _a === void 0 ? void 0 : _a.message);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// Sleep
|
|
|
|
// Sleep
|
|
|
|
const seconds = this.getSleepAmount();
|
|
|
|
const seconds = this.getSleepAmount();
|
|
|
@ -11824,16 +11965,30 @@ module.exports = require("events");
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
var result = {};
|
|
|
|
var result = {};
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
result["default"] = mod;
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
return result;
|
|
|
|
return result;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.fileExistsSync = exports.existsSync = exports.directoryExistsSync = void 0;
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
|
const fs = __importStar(__webpack_require__(747));
|
|
|
|
function directoryExistsSync(path, required) {
|
|
|
|
function directoryExistsSync(path, required) {
|
|
|
|
|
|
|
|
var _a, _b, _c;
|
|
|
|
if (!path) {
|
|
|
|
if (!path) {
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -11842,13 +11997,13 @@ function directoryExistsSync(path, required) {
|
|
|
|
stats = fs.statSync(path);
|
|
|
|
stats = fs.statSync(path);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
if (error.code === 'ENOENT') {
|
|
|
|
if (((_a = error) === null || _a === void 0 ? void 0 : _a.code) === 'ENOENT') {
|
|
|
|
if (!required) {
|
|
|
|
if (!required) {
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
throw new Error(`Directory '${path}' does not exist`);
|
|
|
|
throw new Error(`Directory '${path}' does not exist`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${error.message}`);
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${(_c = (_b = error) === null || _b === void 0 ? void 0 : _b.message) !== null && _c !== void 0 ? _c : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (stats.isDirectory()) {
|
|
|
|
if (stats.isDirectory()) {
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
@ -11860,6 +12015,7 @@ function directoryExistsSync(path, required) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
exports.directoryExistsSync = directoryExistsSync;
|
|
|
|
exports.directoryExistsSync = directoryExistsSync;
|
|
|
|
function existsSync(path) {
|
|
|
|
function existsSync(path) {
|
|
|
|
|
|
|
|
var _a, _b, _c;
|
|
|
|
if (!path) {
|
|
|
|
if (!path) {
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -11867,15 +12023,16 @@ function existsSync(path) {
|
|
|
|
fs.statSync(path);
|
|
|
|
fs.statSync(path);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
if (error.code === 'ENOENT') {
|
|
|
|
if (((_a = error) === null || _a === void 0 ? void 0 : _a.code) === 'ENOENT') {
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${error.message}`);
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${(_c = (_b = error) === null || _b === void 0 ? void 0 : _b.message) !== null && _c !== void 0 ? _c : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
exports.existsSync = existsSync;
|
|
|
|
exports.existsSync = existsSync;
|
|
|
|
function fileExistsSync(path) {
|
|
|
|
function fileExistsSync(path) {
|
|
|
|
|
|
|
|
var _a, _b, _c;
|
|
|
|
if (!path) {
|
|
|
|
if (!path) {
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
throw new Error("Arg 'path' must not be empty");
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -11884,10 +12041,10 @@ function fileExistsSync(path) {
|
|
|
|
stats = fs.statSync(path);
|
|
|
|
stats = fs.statSync(path);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (error) {
|
|
|
|
catch (error) {
|
|
|
|
if (error.code === 'ENOENT') {
|
|
|
|
if (((_a = error) === null || _a === void 0 ? void 0 : _a.code) === 'ENOENT') {
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${error.message}`);
|
|
|
|
throw new Error(`Encountered an error when checking whether path '${path}' exists: ${(_c = (_b = error) === null || _b === void 0 ? void 0 : _b.message) !== null && _c !== void 0 ? _c : error}`);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!stats.isDirectory()) {
|
|
|
|
if (!stats.isDirectory()) {
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
@ -14641,14 +14798,27 @@ function sync (path, options) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
|
|
|
|
|
|
}) : (function(o, m, k, k2) {
|
|
|
|
|
|
|
|
if (k2 === undefined) k2 = k;
|
|
|
|
|
|
|
|
o[k2] = m[k];
|
|
|
|
|
|
|
|
}));
|
|
|
|
|
|
|
|
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
|
|
|
|
|
|
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
|
|
|
|
|
|
}) : function(o, v) {
|
|
|
|
|
|
|
|
o["default"] = v;
|
|
|
|
|
|
|
|
});
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
if (mod && mod.__esModule) return mod;
|
|
|
|
var result = {};
|
|
|
|
var result = {};
|
|
|
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
|
|
|
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
|
|
result["default"] = mod;
|
|
|
|
__setModuleDefault(result, mod);
|
|
|
|
return result;
|
|
|
|
return result;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
|
|
|
|
|
exports.getInputs = void 0;
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const core = __importStar(__webpack_require__(470));
|
|
|
|
const fsHelper = __importStar(__webpack_require__(618));
|
|
|
|
const fsHelper = __importStar(__webpack_require__(618));
|
|
|
|
const github = __importStar(__webpack_require__(469));
|
|
|
|
const github = __importStar(__webpack_require__(469));
|
|
|
|