force build update
parent
8dd3ad4418
commit
57da2b54bb
|
|
@ -0,0 +1,37 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ "$LEFTHOOK" = "0" ]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -t 1 ] ; then
|
||||||
|
exec < /dev/tty ; # <- enables interactive shell
|
||||||
|
fi
|
||||||
|
|
||||||
|
dir="$(git rev-parse --show-toplevel)"
|
||||||
|
|
||||||
|
call_lefthook()
|
||||||
|
{
|
||||||
|
if lefthook.exe -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
eval lefthook.exe $@
|
||||||
|
elif test -f "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe"
|
||||||
|
then
|
||||||
|
eval "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe $@"
|
||||||
|
elif bundle exec lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
bundle exec lefthook $@
|
||||||
|
elif npx @arkweid/lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
npx @arkweid/lefthook $@
|
||||||
|
elif yarn lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
yarn lefthook $@
|
||||||
|
else
|
||||||
|
echo "Can't find lefthook in PATH"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
call_lefthook "run pre-commit $@"
|
||||||
|
|
@ -0,0 +1,37 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ "$LEFTHOOK" = "0" ]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -t 1 ] ; then
|
||||||
|
exec < /dev/tty ; # <- enables interactive shell
|
||||||
|
fi
|
||||||
|
|
||||||
|
dir="$(git rev-parse --show-toplevel)"
|
||||||
|
|
||||||
|
call_lefthook()
|
||||||
|
{
|
||||||
|
if lefthook.exe -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
eval lefthook.exe $@
|
||||||
|
elif test -f "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe"
|
||||||
|
then
|
||||||
|
eval "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe $@"
|
||||||
|
elif bundle exec lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
bundle exec lefthook $@
|
||||||
|
elif npx @arkweid/lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
npx @arkweid/lefthook $@
|
||||||
|
elif yarn lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
yarn lefthook $@
|
||||||
|
else
|
||||||
|
echo "Can't find lefthook in PATH"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
call_lefthook "run pre-push $@"
|
||||||
|
|
@ -0,0 +1,39 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ "$LEFTHOOK" = "0" ]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -t 1 ] ; then
|
||||||
|
exec < /dev/tty ; # <- enables interactive shell
|
||||||
|
fi
|
||||||
|
|
||||||
|
dir="$(git rev-parse --show-toplevel)"
|
||||||
|
|
||||||
|
call_lefthook()
|
||||||
|
{
|
||||||
|
if lefthook.exe -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
eval lefthook.exe $@
|
||||||
|
elif test -f "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe"
|
||||||
|
then
|
||||||
|
eval "$dir/node_modules/@arkweid/lefthook/bin/lefthook.exe $@"
|
||||||
|
elif bundle exec lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
bundle exec lefthook $@
|
||||||
|
elif npx @arkweid/lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
npx @arkweid/lefthook $@
|
||||||
|
elif yarn lefthook -h >/dev/null 2>&1
|
||||||
|
then
|
||||||
|
yarn lefthook $@
|
||||||
|
else
|
||||||
|
echo "Can't find lefthook in PATH"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# lefthook_version: 4ec0fb0fa0acc4d74fc40aaee49039c0
|
||||||
|
|
||||||
|
call_lefthook "install"
|
||||||
|
|
||||||
|
call_lefthook "run prepare-commit-msg $@"
|
||||||
|
|
@ -52,10 +52,9 @@ function runMain() {
|
||||||
}
|
}
|
||||||
model_1.Action.checkCompatibility();
|
model_1.Action.checkCompatibility();
|
||||||
model_1.Cache.verify();
|
model_1.Cache.verify();
|
||||||
const { dockerfile, workspace, actionFolder } = model_1.Action;
|
const { workspace, actionFolder } = model_1.Action;
|
||||||
const buildParameters = yield model_1.BuildParameters.create();
|
const buildParameters = yield model_1.BuildParameters.create();
|
||||||
const baseImage = new model_1.ImageTag(buildParameters);
|
const baseImage = new model_1.ImageTag(buildParameters);
|
||||||
let builtImage;
|
|
||||||
if (buildParameters.cloudRunnerCluster &&
|
if (buildParameters.cloudRunnerCluster &&
|
||||||
buildParameters.cloudRunnerCluster !== '' &&
|
buildParameters.cloudRunnerCluster !== '' &&
|
||||||
buildParameters.cloudRunnerCluster !== 'local') {
|
buildParameters.cloudRunnerCluster !== 'local') {
|
||||||
|
|
@ -68,8 +67,7 @@ function runMain() {
|
||||||
mac_builder_1.default.run(actionFolder, workspace, buildParameters);
|
mac_builder_1.default.run(actionFolder, workspace, buildParameters);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
builtImage = yield model_1.Docker.build({ path: actionFolder, dockerfile, baseImage });
|
yield model_1.Docker.run(baseImage, Object.assign({ workspace, actionFolder }, buildParameters));
|
||||||
yield model_1.Docker.run(builtImage, Object.assign({ workspace }, buildParameters));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Set output
|
// Set output
|
||||||
|
|
@ -117,19 +115,6 @@ class Action {
|
||||||
static get actionFolder() {
|
static get actionFolder() {
|
||||||
return `${Action.rootFolder}/dist`;
|
return `${Action.rootFolder}/dist`;
|
||||||
}
|
}
|
||||||
static get dockerfile() {
|
|
||||||
const currentPlatform = process.platform;
|
|
||||||
switch (currentPlatform) {
|
|
||||||
case 'linux':
|
|
||||||
return `${Action.actionFolder}/platforms/ubuntu/Dockerfile`;
|
|
||||||
case 'win32':
|
|
||||||
return `${Action.actionFolder}/platforms/windows/Dockerfile`;
|
|
||||||
case 'darwin':
|
|
||||||
return 'unused'; //Mac doesn't use a container
|
|
||||||
default:
|
|
||||||
throw new Error(`No Dockerfile for currently unsupported platform: ${currentPlatform}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
static get workspace() {
|
static get workspace() {
|
||||||
return process.env.GITHUB_WORKSPACE;
|
return process.env.GITHUB_WORKSPACE;
|
||||||
}
|
}
|
||||||
|
|
@ -264,6 +249,8 @@ class BuildParameters {
|
||||||
const buildVersion = yield versioning_1.default.determineVersion(input_1.default.versioningStrategy, input_1.default.specifiedVersion);
|
const buildVersion = yield versioning_1.default.determineVersion(input_1.default.versioningStrategy, input_1.default.specifiedVersion);
|
||||||
const androidVersionCode = android_versioning_1.default.determineVersionCode(buildVersion, input_1.default.androidVersionCode);
|
const androidVersionCode = android_versioning_1.default.determineVersionCode(buildVersion, input_1.default.androidVersionCode);
|
||||||
const androidSdkManagerParameters = android_versioning_1.default.determineSdkManagerParameters(input_1.default.androidTargetSdkVersion);
|
const androidSdkManagerParameters = android_versioning_1.default.determineSdkManagerParameters(input_1.default.androidTargetSdkVersion);
|
||||||
|
// Todo - Don't use process.env directly, that's what the input model class is for.
|
||||||
|
// ---
|
||||||
let unitySerial = '';
|
let unitySerial = '';
|
||||||
if (!process.env.UNITY_SERIAL && input_1.default.githubInputEnabled && input_1.default.cliOptions === undefined) {
|
if (!process.env.UNITY_SERIAL && input_1.default.githubInputEnabled && input_1.default.cliOptions === undefined) {
|
||||||
//No serial was present so it is a personal license that we need to convert
|
//No serial was present so it is a personal license that we need to convert
|
||||||
|
|
@ -3220,7 +3207,7 @@ class BuildAutomationWorkflow {
|
||||||
static get FullWorkflow() {
|
static get FullWorkflow() {
|
||||||
const hooks = cloud_runner_build_command_process_1.CloudRunnerBuildCommandProcessor.getHooks(cloud_runner_1.default.buildParameters.customJobHooks).filter((x) => x.step.includes(`setup`));
|
const hooks = cloud_runner_build_command_process_1.CloudRunnerBuildCommandProcessor.getHooks(cloud_runner_1.default.buildParameters.customJobHooks).filter((x) => x.step.includes(`setup`));
|
||||||
return `apt-get update
|
return `apt-get update
|
||||||
apt-get install -y -q zip tree nodejs git-lfs jq unzip
|
apt-get install -y -q zip tree nodejs git-lfs jq unzip git
|
||||||
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
||||||
export GITHUB_WORKSPACE="${cloud_runner_folders_1.CloudRunnerFolders.repoPathFull}"
|
export GITHUB_WORKSPACE="${cloud_runner_folders_1.CloudRunnerFolders.repoPathFull}"
|
||||||
${BuildAutomationWorkflow.SetupCommands}
|
${BuildAutomationWorkflow.SetupCommands}
|
||||||
|
|
@ -3250,7 +3237,9 @@ class BuildAutomationWorkflow {
|
||||||
.replace(/\\/g, `/`)}" "/steps"
|
.replace(/\\/g, `/`)}" "/steps"
|
||||||
chmod -R +x "/entrypoint.sh"
|
chmod -R +x "/entrypoint.sh"
|
||||||
chmod -R +x "/steps"
|
chmod -R +x "/steps"
|
||||||
|
echo "enter build scripts"
|
||||||
/entrypoint.sh
|
/entrypoint.sh
|
||||||
|
echo "post build scripts"
|
||||||
cd "${cloud_runner_folders_1.CloudRunnerFolders.libraryFolderFull.replace(/\\/g, `/`)}/.."
|
cd "${cloud_runner_folders_1.CloudRunnerFolders.libraryFolderFull.replace(/\\/g, `/`)}/.."
|
||||||
zip -r "lib-${cloud_runner_1.default.buildParameters.buildGuid}.zip" "Library"
|
zip -r "lib-${cloud_runner_1.default.buildParameters.buildGuid}.zip" "Library"
|
||||||
mv "lib-${cloud_runner_1.default.buildParameters.buildGuid}.zip" "${cloud_runner_folders_1.CloudRunnerFolders.cacheFolderFull.replace(/\\/g, `/`)}/Library"
|
mv "lib-${cloud_runner_1.default.buildParameters.buildGuid}.zip" "${cloud_runner_folders_1.CloudRunnerFolders.cacheFolderFull.replace(/\\/g, `/`)}/Library"
|
||||||
|
|
@ -3406,67 +3395,67 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
||||||
};
|
};
|
||||||
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||||
const exec_1 = __nccwpck_require__(71514);
|
const exec_1 = __nccwpck_require__(71514);
|
||||||
const image_tag_1 = __importDefault(__nccwpck_require__(57648));
|
|
||||||
const image_environment_factory_1 = __importDefault(__nccwpck_require__(25145));
|
const image_environment_factory_1 = __importDefault(__nccwpck_require__(25145));
|
||||||
const fs_1 = __nccwpck_require__(57147);
|
const fs_1 = __nccwpck_require__(57147);
|
||||||
const path_1 = __importDefault(__nccwpck_require__(71017));
|
const path_1 = __importDefault(__nccwpck_require__(71017));
|
||||||
class Docker {
|
class Docker {
|
||||||
static build(buildParameters, silent = false) {
|
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
|
||||||
const { path: buildPath, dockerfile, baseImage } = buildParameters;
|
|
||||||
const { version, platform } = baseImage;
|
|
||||||
const tag = new image_tag_1.default({ repository: '', name: 'unity-builder', version, platform });
|
|
||||||
const command = `docker build ${buildPath} \
|
|
||||||
--file ${dockerfile} \
|
|
||||||
--build-arg IMAGE=${baseImage} \
|
|
||||||
--tag ${tag}`;
|
|
||||||
yield exec_1.exec(command, undefined, { silent });
|
|
||||||
return tag;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
static run(image, parameters, silent = false) {
|
static run(image, parameters, silent = false) {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
const { workspace, unitySerial, runnerTempPath, sshAgent } = parameters;
|
let runCommand = '';
|
||||||
const baseOsSpecificArguments = this.getBaseOsSpecificArguments(process.platform, workspace, unitySerial, runnerTempPath, sshAgent);
|
switch (process.platform) {
|
||||||
const runCommand = `docker run \
|
case 'linux':
|
||||||
--workdir /github/workspace \
|
runCommand = this.getLinuxCommand(image, parameters);
|
||||||
--rm \
|
break;
|
||||||
${image_environment_factory_1.default.getEnvVarString(parameters)} \
|
case 'win32':
|
||||||
${baseOsSpecificArguments} \
|
runCommand = this.getWindowsCommand(image, parameters);
|
||||||
${image}`;
|
}
|
||||||
yield exec_1.exec(runCommand, undefined, { silent });
|
yield exec_1.exec(runCommand, undefined, { silent });
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
static getBaseOsSpecificArguments(baseOs, workspace, unitySerial, runnerTemporaryPath, sshAgent) {
|
static getLinuxCommand(image, parameters) {
|
||||||
switch (baseOs) {
|
const { workspace, actionFolder, runnerTempPath, sshAgent } = parameters;
|
||||||
case 'linux': {
|
const githubHome = path_1.default.join(runnerTempPath, '_github_home');
|
||||||
const githubHome = path_1.default.join(runnerTemporaryPath, '_github_home');
|
if (!fs_1.existsSync(githubHome))
|
||||||
if (!fs_1.existsSync(githubHome))
|
fs_1.mkdirSync(githubHome);
|
||||||
fs_1.mkdirSync(githubHome);
|
const githubWorkflow = path_1.default.join(runnerTempPath, '_github_workflow');
|
||||||
const githubWorkflow = path_1.default.join(runnerTemporaryPath, '_github_workflow');
|
if (!fs_1.existsSync(githubWorkflow))
|
||||||
if (!fs_1.existsSync(githubWorkflow))
|
fs_1.mkdirSync(githubWorkflow);
|
||||||
fs_1.mkdirSync(githubWorkflow);
|
return `docker run \
|
||||||
return `--env UNITY_SERIAL \
|
--workdir /github/workspace \
|
||||||
--env GITHUB_WORKSPACE=/github/workspace \
|
--rm \
|
||||||
${sshAgent ? '--env SSH_AUTH_SOCK=/ssh-agent' : ''} \
|
${image_environment_factory_1.default.getEnvVarString(parameters)} \
|
||||||
--volume "/var/run/docker.sock":"/var/run/docker.sock:z" \
|
--env UNITY_SERIAL \
|
||||||
--volume "${githubHome}":"/root:z" \
|
--env GITHUB_WORKSPACE=/github/workspace \
|
||||||
--volume "${githubWorkflow}":"/github/workflow:z" \
|
${sshAgent ? '--env SSH_AUTH_SOCK=/ssh-agent' : ''} \
|
||||||
--volume "${workspace}":"/github/workspace:z" \
|
--volume "${githubHome}":"/root:z" \
|
||||||
${sshAgent ? `--volume ${sshAgent}:/ssh-agent` : ''} \
|
--volume "${githubWorkflow}":"/github/workflow:z" \
|
||||||
${sshAgent ? '--volume /home/runner/.ssh/known_hosts:/root/.ssh/known_hosts:ro' : ''}`;
|
--volume "${workspace}":"/github/workspace:z" \
|
||||||
}
|
--volume "${actionFolder}/default-build-script:/UnityBuilderAction:z" \
|
||||||
case 'win32':
|
--volume "${actionFolder}/platforms/ubuntu/steps:/steps:z" \
|
||||||
return `--env UNITY_SERIAL="${unitySerial}" \
|
--volume "${actionFolder}/platforms/ubuntu/entrypoint.sh:/entrypoint.sh:z" \
|
||||||
--env GITHUB_WORKSPACE=c:/github/workspace \
|
${sshAgent ? `--volume ${sshAgent}:/ssh-agent` : ''} \
|
||||||
--volume "${workspace}":"c:/github/workspace" \
|
${sshAgent ? '--volume /home/runner/.ssh/known_hosts:/root/.ssh/known_hosts:ro' : ''} \
|
||||||
--volume "c:/regkeys":"c:/regkeys" \
|
${image} \
|
||||||
--volume "C:/Program Files (x86)/Microsoft Visual Studio":"C:/Program Files (x86)/Microsoft Visual Studio" \
|
/bin/bash -c /entrypoint.sh`;
|
||||||
--volume "C:/Program Files (x86)/Windows Kits":"C:/Program Files (x86)/Windows Kits" \
|
}
|
||||||
--volume "C:/ProgramData/Microsoft/VisualStudio":"C:/ProgramData/Microsoft/VisualStudio"`;
|
static getWindowsCommand(image, parameters) {
|
||||||
//Note: When upgrading to Server 2022, we will need to move to just "program files" since VS will be 64-bit
|
const { workspace, actionFolder, unitySerial } = parameters;
|
||||||
}
|
return `docker run \
|
||||||
return '';
|
--workdir /github/workspace \
|
||||||
|
--rm \
|
||||||
|
${image_environment_factory_1.default.getEnvVarString(parameters)} \
|
||||||
|
--env UNITY_SERIAL="${unitySerial}" \
|
||||||
|
--env GITHUB_WORKSPACE=c:/github/workspace \
|
||||||
|
--volume "${workspace}":"c:/github/workspace" \
|
||||||
|
--volume "c:/regkeys":"c:/regkeys" \
|
||||||
|
--volume "C:/Program Files (x86)/Microsoft Visual Studio":"C:/Program Files (x86)/Microsoft Visual Studio" \
|
||||||
|
--volume "C:/Program Files (x86)/Windows Kits":"C:/Program Files (x86)/Windows Kits" \
|
||||||
|
--volume "C:/ProgramData/Microsoft/VisualStudio":"C:/ProgramData/Microsoft/VisualStudio" \
|
||||||
|
--volume "${actionFolder}/default-build-script":"c:/UnityBuilderAction" \
|
||||||
|
--volume "${actionFolder}/platforms/windows":"c:/steps" \
|
||||||
|
--volume "${actionFolder}/BlankProject":"c:/BlankProject" \
|
||||||
|
${image} \
|
||||||
|
powershell c:/steps/entrypoint.ps1`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
exports["default"] = Docker;
|
exports["default"] = Docker;
|
||||||
|
|
@ -4141,7 +4130,7 @@ class Input {
|
||||||
return Input.getInput('androidKeyaliasPass') || '';
|
return Input.getInput('androidKeyaliasPass') || '';
|
||||||
}
|
}
|
||||||
static get androidTargetSdkVersion() {
|
static get androidTargetSdkVersion() {
|
||||||
return core.getInput('androidTargetSdkVersion') || '';
|
return Input.getInput('androidTargetSdkVersion') || '';
|
||||||
}
|
}
|
||||||
static get sshAgent() {
|
static get sshAgent() {
|
||||||
return Input.getInput('sshAgent') || '';
|
return Input.getInput('sshAgent') || '';
|
||||||
|
|
@ -4726,6 +4715,9 @@ class System {
|
||||||
throw new Error(`Failed to run "${commandAsString}".\n ${message}`);
|
throw new Error(`Failed to run "${commandAsString}".\n ${message}`);
|
||||||
};
|
};
|
||||||
try {
|
try {
|
||||||
|
if (command.trim() === '') {
|
||||||
|
throw new Error(`Failed to execute empty command`);
|
||||||
|
}
|
||||||
const exitCode = yield exec_1.exec(command, arguments_, Object.assign({ silent: true, listeners }, options));
|
const exitCode = yield exec_1.exec(command, arguments_, Object.assign({ silent: true, listeners }, options));
|
||||||
showOutput();
|
showOutput();
|
||||||
if (exitCode !== 0) {
|
if (exitCode !== 0) {
|
||||||
|
|
@ -113770,7 +113762,7 @@ module.exports = makeError;
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
const os = __nccwpck_require__(22037);
|
const os = __nccwpck_require__(22037);
|
||||||
const onExit = __nccwpck_require__(27266);
|
const onExit = __nccwpck_require__(24931);
|
||||||
|
|
||||||
const DEFAULT_FORCE_KILL_TIMEOUT = 1000 * 5;
|
const DEFAULT_FORCE_KILL_TIMEOUT = 1000 * 5;
|
||||||
|
|
||||||
|
|
@ -123338,275 +123330,6 @@ class TokenSet {
|
||||||
module.exports = TokenSet;
|
module.exports = TokenSet;
|
||||||
|
|
||||||
|
|
||||||
/***/ }),
|
|
||||||
|
|
||||||
/***/ 27266:
|
|
||||||
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
||||||
|
|
||||||
// Note: since nyc uses this module to output coverage, any lines
|
|
||||||
// that are in the direct sync flow of nyc's outputCoverage are
|
|
||||||
// ignored, since we can never get coverage for them.
|
|
||||||
// grab a reference to node's real process object right away
|
|
||||||
var process = global.process
|
|
||||||
|
|
||||||
const processOk = function (process) {
|
|
||||||
return process &&
|
|
||||||
typeof process === 'object' &&
|
|
||||||
typeof process.removeListener === 'function' &&
|
|
||||||
typeof process.emit === 'function' &&
|
|
||||||
typeof process.reallyExit === 'function' &&
|
|
||||||
typeof process.listeners === 'function' &&
|
|
||||||
typeof process.kill === 'function' &&
|
|
||||||
typeof process.pid === 'number' &&
|
|
||||||
typeof process.on === 'function'
|
|
||||||
}
|
|
||||||
|
|
||||||
// some kind of non-node environment, just no-op
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (!processOk(process)) {
|
|
||||||
module.exports = function () {
|
|
||||||
return function () {}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
var assert = __nccwpck_require__(39491)
|
|
||||||
var signals = __nccwpck_require__(38506)
|
|
||||||
var isWin = /^win/i.test(process.platform)
|
|
||||||
|
|
||||||
var EE = __nccwpck_require__(82361)
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (typeof EE !== 'function') {
|
|
||||||
EE = EE.EventEmitter
|
|
||||||
}
|
|
||||||
|
|
||||||
var emitter
|
|
||||||
if (process.__signal_exit_emitter__) {
|
|
||||||
emitter = process.__signal_exit_emitter__
|
|
||||||
} else {
|
|
||||||
emitter = process.__signal_exit_emitter__ = new EE()
|
|
||||||
emitter.count = 0
|
|
||||||
emitter.emitted = {}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Because this emitter is a global, we have to check to see if a
|
|
||||||
// previous version of this library failed to enable infinite listeners.
|
|
||||||
// I know what you're about to say. But literally everything about
|
|
||||||
// signal-exit is a compromise with evil. Get used to it.
|
|
||||||
if (!emitter.infinite) {
|
|
||||||
emitter.setMaxListeners(Infinity)
|
|
||||||
emitter.infinite = true
|
|
||||||
}
|
|
||||||
|
|
||||||
module.exports = function (cb, opts) {
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (!processOk(global.process)) {
|
|
||||||
return function () {}
|
|
||||||
}
|
|
||||||
assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler')
|
|
||||||
|
|
||||||
if (loaded === false) {
|
|
||||||
load()
|
|
||||||
}
|
|
||||||
|
|
||||||
var ev = 'exit'
|
|
||||||
if (opts && opts.alwaysLast) {
|
|
||||||
ev = 'afterexit'
|
|
||||||
}
|
|
||||||
|
|
||||||
var remove = function () {
|
|
||||||
emitter.removeListener(ev, cb)
|
|
||||||
if (emitter.listeners('exit').length === 0 &&
|
|
||||||
emitter.listeners('afterexit').length === 0) {
|
|
||||||
unload()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
emitter.on(ev, cb)
|
|
||||||
|
|
||||||
return remove
|
|
||||||
}
|
|
||||||
|
|
||||||
var unload = function unload () {
|
|
||||||
if (!loaded || !processOk(global.process)) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
loaded = false
|
|
||||||
|
|
||||||
signals.forEach(function (sig) {
|
|
||||||
try {
|
|
||||||
process.removeListener(sig, sigListeners[sig])
|
|
||||||
} catch (er) {}
|
|
||||||
})
|
|
||||||
process.emit = originalProcessEmit
|
|
||||||
process.reallyExit = originalProcessReallyExit
|
|
||||||
emitter.count -= 1
|
|
||||||
}
|
|
||||||
module.exports.unload = unload
|
|
||||||
|
|
||||||
var emit = function emit (event, code, signal) {
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (emitter.emitted[event]) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
emitter.emitted[event] = true
|
|
||||||
emitter.emit(event, code, signal)
|
|
||||||
}
|
|
||||||
|
|
||||||
// { <signal>: <listener fn>, ... }
|
|
||||||
var sigListeners = {}
|
|
||||||
signals.forEach(function (sig) {
|
|
||||||
sigListeners[sig] = function listener () {
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (!processOk(global.process)) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
// If there are no other listeners, an exit is coming!
|
|
||||||
// Simplest way: remove us and then re-send the signal.
|
|
||||||
// We know that this will kill the process, so we can
|
|
||||||
// safely emit now.
|
|
||||||
var listeners = process.listeners(sig)
|
|
||||||
if (listeners.length === emitter.count) {
|
|
||||||
unload()
|
|
||||||
emit('exit', null, sig)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
emit('afterexit', null, sig)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
if (isWin && sig === 'SIGHUP') {
|
|
||||||
// "SIGHUP" throws an `ENOSYS` error on Windows,
|
|
||||||
// so use a supported signal instead
|
|
||||||
sig = 'SIGINT'
|
|
||||||
}
|
|
||||||
/* istanbul ignore next */
|
|
||||||
process.kill(process.pid, sig)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
module.exports.signals = function () {
|
|
||||||
return signals
|
|
||||||
}
|
|
||||||
|
|
||||||
var loaded = false
|
|
||||||
|
|
||||||
var load = function load () {
|
|
||||||
if (loaded || !processOk(global.process)) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
loaded = true
|
|
||||||
|
|
||||||
// This is the number of onSignalExit's that are in play.
|
|
||||||
// It's important so that we can count the correct number of
|
|
||||||
// listeners on signals, and don't wait for the other one to
|
|
||||||
// handle it instead of us.
|
|
||||||
emitter.count += 1
|
|
||||||
|
|
||||||
signals = signals.filter(function (sig) {
|
|
||||||
try {
|
|
||||||
process.on(sig, sigListeners[sig])
|
|
||||||
return true
|
|
||||||
} catch (er) {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
process.emit = processEmit
|
|
||||||
process.reallyExit = processReallyExit
|
|
||||||
}
|
|
||||||
module.exports.load = load
|
|
||||||
|
|
||||||
var originalProcessReallyExit = process.reallyExit
|
|
||||||
var processReallyExit = function processReallyExit (code) {
|
|
||||||
/* istanbul ignore if */
|
|
||||||
if (!processOk(global.process)) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
process.exitCode = code || /* istanbul ignore next */ 0
|
|
||||||
emit('exit', process.exitCode, null)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
emit('afterexit', process.exitCode, null)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
originalProcessReallyExit.call(process, process.exitCode)
|
|
||||||
}
|
|
||||||
|
|
||||||
var originalProcessEmit = process.emit
|
|
||||||
var processEmit = function processEmit (ev, arg) {
|
|
||||||
if (ev === 'exit' && processOk(global.process)) {
|
|
||||||
/* istanbul ignore else */
|
|
||||||
if (arg !== undefined) {
|
|
||||||
process.exitCode = arg
|
|
||||||
}
|
|
||||||
var ret = originalProcessEmit.apply(this, arguments)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
emit('exit', process.exitCode, null)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
emit('afterexit', process.exitCode, null)
|
|
||||||
/* istanbul ignore next */
|
|
||||||
return ret
|
|
||||||
} else {
|
|
||||||
return originalProcessEmit.apply(this, arguments)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/***/ }),
|
|
||||||
|
|
||||||
/***/ 38506:
|
|
||||||
/***/ ((module) => {
|
|
||||||
|
|
||||||
// This is not the set of all possible signals.
|
|
||||||
//
|
|
||||||
// It IS, however, the set of all signals that trigger
|
|
||||||
// an exit on either Linux or BSD systems. Linux is a
|
|
||||||
// superset of the signal names supported on BSD, and
|
|
||||||
// the unknown signals just fail to register, so we can
|
|
||||||
// catch that easily enough.
|
|
||||||
//
|
|
||||||
// Don't bother with SIGKILL. It's uncatchable, which
|
|
||||||
// means that we can't fire any callbacks anyway.
|
|
||||||
//
|
|
||||||
// If a user does happen to register a handler on a non-
|
|
||||||
// fatal signal like SIGWINCH or something, and then
|
|
||||||
// exit, it'll end up firing `process.emit('exit')`, so
|
|
||||||
// the handler will be fired anyway.
|
|
||||||
//
|
|
||||||
// SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised
|
|
||||||
// artificially, inherently leave the process in a
|
|
||||||
// state from which it is not safe to try and enter JS
|
|
||||||
// listeners.
|
|
||||||
module.exports = [
|
|
||||||
'SIGABRT',
|
|
||||||
'SIGALRM',
|
|
||||||
'SIGHUP',
|
|
||||||
'SIGINT',
|
|
||||||
'SIGTERM'
|
|
||||||
]
|
|
||||||
|
|
||||||
if (process.platform !== 'win32') {
|
|
||||||
module.exports.push(
|
|
||||||
'SIGVTALRM',
|
|
||||||
'SIGXCPU',
|
|
||||||
'SIGXFSZ',
|
|
||||||
'SIGUSR2',
|
|
||||||
'SIGTRAP',
|
|
||||||
'SIGSYS',
|
|
||||||
'SIGQUIT',
|
|
||||||
'SIGIOT'
|
|
||||||
// should detect profiler and enable/disable accordingly.
|
|
||||||
// see #21
|
|
||||||
// 'SIGPROF'
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
if (process.platform === 'linux') {
|
|
||||||
module.exports.push(
|
|
||||||
'SIGIO',
|
|
||||||
'SIGPOLL',
|
|
||||||
'SIGPWR',
|
|
||||||
'SIGSTKFLT',
|
|
||||||
'SIGUNUSED'
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/***/ }),
|
/***/ }),
|
||||||
|
|
||||||
/***/ 39436:
|
/***/ 39436:
|
||||||
|
|
@ -335019,6 +334742,275 @@ function _which(options, cmd) {
|
||||||
module.exports = _which;
|
module.exports = _which;
|
||||||
|
|
||||||
|
|
||||||
|
/***/ }),
|
||||||
|
|
||||||
|
/***/ 24931:
|
||||||
|
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
|
||||||
|
|
||||||
|
// Note: since nyc uses this module to output coverage, any lines
|
||||||
|
// that are in the direct sync flow of nyc's outputCoverage are
|
||||||
|
// ignored, since we can never get coverage for them.
|
||||||
|
// grab a reference to node's real process object right away
|
||||||
|
var process = global.process
|
||||||
|
|
||||||
|
const processOk = function (process) {
|
||||||
|
return process &&
|
||||||
|
typeof process === 'object' &&
|
||||||
|
typeof process.removeListener === 'function' &&
|
||||||
|
typeof process.emit === 'function' &&
|
||||||
|
typeof process.reallyExit === 'function' &&
|
||||||
|
typeof process.listeners === 'function' &&
|
||||||
|
typeof process.kill === 'function' &&
|
||||||
|
typeof process.pid === 'number' &&
|
||||||
|
typeof process.on === 'function'
|
||||||
|
}
|
||||||
|
|
||||||
|
// some kind of non-node environment, just no-op
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (!processOk(process)) {
|
||||||
|
module.exports = function () {
|
||||||
|
return function () {}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
var assert = __nccwpck_require__(39491)
|
||||||
|
var signals = __nccwpck_require__(63710)
|
||||||
|
var isWin = /^win/i.test(process.platform)
|
||||||
|
|
||||||
|
var EE = __nccwpck_require__(82361)
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (typeof EE !== 'function') {
|
||||||
|
EE = EE.EventEmitter
|
||||||
|
}
|
||||||
|
|
||||||
|
var emitter
|
||||||
|
if (process.__signal_exit_emitter__) {
|
||||||
|
emitter = process.__signal_exit_emitter__
|
||||||
|
} else {
|
||||||
|
emitter = process.__signal_exit_emitter__ = new EE()
|
||||||
|
emitter.count = 0
|
||||||
|
emitter.emitted = {}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Because this emitter is a global, we have to check to see if a
|
||||||
|
// previous version of this library failed to enable infinite listeners.
|
||||||
|
// I know what you're about to say. But literally everything about
|
||||||
|
// signal-exit is a compromise with evil. Get used to it.
|
||||||
|
if (!emitter.infinite) {
|
||||||
|
emitter.setMaxListeners(Infinity)
|
||||||
|
emitter.infinite = true
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = function (cb, opts) {
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (!processOk(global.process)) {
|
||||||
|
return function () {}
|
||||||
|
}
|
||||||
|
assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler')
|
||||||
|
|
||||||
|
if (loaded === false) {
|
||||||
|
load()
|
||||||
|
}
|
||||||
|
|
||||||
|
var ev = 'exit'
|
||||||
|
if (opts && opts.alwaysLast) {
|
||||||
|
ev = 'afterexit'
|
||||||
|
}
|
||||||
|
|
||||||
|
var remove = function () {
|
||||||
|
emitter.removeListener(ev, cb)
|
||||||
|
if (emitter.listeners('exit').length === 0 &&
|
||||||
|
emitter.listeners('afterexit').length === 0) {
|
||||||
|
unload()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
emitter.on(ev, cb)
|
||||||
|
|
||||||
|
return remove
|
||||||
|
}
|
||||||
|
|
||||||
|
var unload = function unload () {
|
||||||
|
if (!loaded || !processOk(global.process)) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
loaded = false
|
||||||
|
|
||||||
|
signals.forEach(function (sig) {
|
||||||
|
try {
|
||||||
|
process.removeListener(sig, sigListeners[sig])
|
||||||
|
} catch (er) {}
|
||||||
|
})
|
||||||
|
process.emit = originalProcessEmit
|
||||||
|
process.reallyExit = originalProcessReallyExit
|
||||||
|
emitter.count -= 1
|
||||||
|
}
|
||||||
|
module.exports.unload = unload
|
||||||
|
|
||||||
|
var emit = function emit (event, code, signal) {
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (emitter.emitted[event]) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
emitter.emitted[event] = true
|
||||||
|
emitter.emit(event, code, signal)
|
||||||
|
}
|
||||||
|
|
||||||
|
// { <signal>: <listener fn>, ... }
|
||||||
|
var sigListeners = {}
|
||||||
|
signals.forEach(function (sig) {
|
||||||
|
sigListeners[sig] = function listener () {
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (!processOk(global.process)) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
// If there are no other listeners, an exit is coming!
|
||||||
|
// Simplest way: remove us and then re-send the signal.
|
||||||
|
// We know that this will kill the process, so we can
|
||||||
|
// safely emit now.
|
||||||
|
var listeners = process.listeners(sig)
|
||||||
|
if (listeners.length === emitter.count) {
|
||||||
|
unload()
|
||||||
|
emit('exit', null, sig)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
emit('afterexit', null, sig)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
if (isWin && sig === 'SIGHUP') {
|
||||||
|
// "SIGHUP" throws an `ENOSYS` error on Windows,
|
||||||
|
// so use a supported signal instead
|
||||||
|
sig = 'SIGINT'
|
||||||
|
}
|
||||||
|
/* istanbul ignore next */
|
||||||
|
process.kill(process.pid, sig)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
module.exports.signals = function () {
|
||||||
|
return signals
|
||||||
|
}
|
||||||
|
|
||||||
|
var loaded = false
|
||||||
|
|
||||||
|
var load = function load () {
|
||||||
|
if (loaded || !processOk(global.process)) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
loaded = true
|
||||||
|
|
||||||
|
// This is the number of onSignalExit's that are in play.
|
||||||
|
// It's important so that we can count the correct number of
|
||||||
|
// listeners on signals, and don't wait for the other one to
|
||||||
|
// handle it instead of us.
|
||||||
|
emitter.count += 1
|
||||||
|
|
||||||
|
signals = signals.filter(function (sig) {
|
||||||
|
try {
|
||||||
|
process.on(sig, sigListeners[sig])
|
||||||
|
return true
|
||||||
|
} catch (er) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
process.emit = processEmit
|
||||||
|
process.reallyExit = processReallyExit
|
||||||
|
}
|
||||||
|
module.exports.load = load
|
||||||
|
|
||||||
|
var originalProcessReallyExit = process.reallyExit
|
||||||
|
var processReallyExit = function processReallyExit (code) {
|
||||||
|
/* istanbul ignore if */
|
||||||
|
if (!processOk(global.process)) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
process.exitCode = code || /* istanbul ignore next */ 0
|
||||||
|
emit('exit', process.exitCode, null)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
emit('afterexit', process.exitCode, null)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
originalProcessReallyExit.call(process, process.exitCode)
|
||||||
|
}
|
||||||
|
|
||||||
|
var originalProcessEmit = process.emit
|
||||||
|
var processEmit = function processEmit (ev, arg) {
|
||||||
|
if (ev === 'exit' && processOk(global.process)) {
|
||||||
|
/* istanbul ignore else */
|
||||||
|
if (arg !== undefined) {
|
||||||
|
process.exitCode = arg
|
||||||
|
}
|
||||||
|
var ret = originalProcessEmit.apply(this, arguments)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
emit('exit', process.exitCode, null)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
emit('afterexit', process.exitCode, null)
|
||||||
|
/* istanbul ignore next */
|
||||||
|
return ret
|
||||||
|
} else {
|
||||||
|
return originalProcessEmit.apply(this, arguments)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/***/ }),
|
||||||
|
|
||||||
|
/***/ 63710:
|
||||||
|
/***/ ((module) => {
|
||||||
|
|
||||||
|
// This is not the set of all possible signals.
|
||||||
|
//
|
||||||
|
// It IS, however, the set of all signals that trigger
|
||||||
|
// an exit on either Linux or BSD systems. Linux is a
|
||||||
|
// superset of the signal names supported on BSD, and
|
||||||
|
// the unknown signals just fail to register, so we can
|
||||||
|
// catch that easily enough.
|
||||||
|
//
|
||||||
|
// Don't bother with SIGKILL. It's uncatchable, which
|
||||||
|
// means that we can't fire any callbacks anyway.
|
||||||
|
//
|
||||||
|
// If a user does happen to register a handler on a non-
|
||||||
|
// fatal signal like SIGWINCH or something, and then
|
||||||
|
// exit, it'll end up firing `process.emit('exit')`, so
|
||||||
|
// the handler will be fired anyway.
|
||||||
|
//
|
||||||
|
// SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised
|
||||||
|
// artificially, inherently leave the process in a
|
||||||
|
// state from which it is not safe to try and enter JS
|
||||||
|
// listeners.
|
||||||
|
module.exports = [
|
||||||
|
'SIGABRT',
|
||||||
|
'SIGALRM',
|
||||||
|
'SIGHUP',
|
||||||
|
'SIGINT',
|
||||||
|
'SIGTERM'
|
||||||
|
]
|
||||||
|
|
||||||
|
if (process.platform !== 'win32') {
|
||||||
|
module.exports.push(
|
||||||
|
'SIGVTALRM',
|
||||||
|
'SIGXCPU',
|
||||||
|
'SIGXFSZ',
|
||||||
|
'SIGUSR2',
|
||||||
|
'SIGTRAP',
|
||||||
|
'SIGSYS',
|
||||||
|
'SIGQUIT',
|
||||||
|
'SIGIOT'
|
||||||
|
// should detect profiler and enable/disable accordingly.
|
||||||
|
// see #21
|
||||||
|
// 'SIGPROF'
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (process.platform === 'linux') {
|
||||||
|
module.exports.push(
|
||||||
|
'SIGIO',
|
||||||
|
'SIGPOLL',
|
||||||
|
'SIGPWR',
|
||||||
|
'SIGSTKFLT',
|
||||||
|
'SIGUNUSED'
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/***/ }),
|
/***/ }),
|
||||||
|
|
||||||
/***/ 66126:
|
/***/ 66126:
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -78,7 +78,7 @@ export class BuildAutomationWorkflow implements WorkflowInterface {
|
||||||
x.step.includes(`setup`),
|
x.step.includes(`setup`),
|
||||||
);
|
);
|
||||||
return `apt-get update
|
return `apt-get update
|
||||||
apt-get install -y -q zip tree nodejs git-lfs jq unzip
|
apt-get install -y -q zip tree nodejs git-lfs jq unzip git
|
||||||
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
||||||
export GITHUB_WORKSPACE="${CloudRunnerFolders.repoPathFull}"
|
export GITHUB_WORKSPACE="${CloudRunnerFolders.repoPathFull}"
|
||||||
${BuildAutomationWorkflow.SetupCommands}
|
${BuildAutomationWorkflow.SetupCommands}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue