pull/524/head
Frostebite 2023-03-17 21:27:07 +00:00
parent 0dfbf442e7
commit 4664914de6
6 changed files with 21 additions and 23 deletions

18
dist/index.js vendored
View File

@ -302,8 +302,8 @@ class BuildParameters {
asyncWorkflow: cloud_runner_options_1.default.asyncCloudRunner, asyncWorkflow: cloud_runner_options_1.default.asyncCloudRunner,
githubCheckId: cloud_runner_options_1.default.githubCheckId, githubCheckId: cloud_runner_options_1.default.githubCheckId,
triggerWorkflowOnComplete: cloud_runner_options_1.default.triggerWorkflowOnComplete, triggerWorkflowOnComplete: cloud_runner_options_1.default.triggerWorkflowOnComplete,
cloudRunnerDebugSkipLFS: cloud_runner_options_1.default.cloudRunnerDebugSkipLFS, skipLFS: cloud_runner_options_1.default.skipLFS,
cloudRunnerDebugSkipCache: cloud_runner_options_1.default.cloudRunnerDebugSkipCache, skipCache: cloud_runner_options_1.default.skipCache,
cacheUnityInstallationOnMac: input_1.default.cacheUnityInstallationOnMac, cacheUnityInstallationOnMac: input_1.default.cacheUnityInstallationOnMac,
unityHubVersionOnMac: input_1.default.unityHubVersionOnMac, unityHubVersionOnMac: input_1.default.unityHubVersionOnMac,
}; };
@ -868,11 +868,11 @@ class CloudRunnerOptions {
static get cloudRunnerDebugEnv() { static get cloudRunnerDebugEnv() {
return CloudRunnerOptions.getInput(`cloudRunnerDebugEnv`) === `true` || false; return CloudRunnerOptions.getInput(`cloudRunnerDebugEnv`) === `true` || false;
} }
static get cloudRunnerDebugSkipLFS() { static get skipLFS() {
return CloudRunnerOptions.getInput(`cloudRunnerDebugSkipLFS`) === `true` || false; return CloudRunnerOptions.getInput(`skipLFS`) === `true` || false;
} }
static get cloudRunnerDebugSkipCache() { static get skipCache() {
return CloudRunnerOptions.getInput(`cloudRunnerDebugSkipCache`) === `true` || false; return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
} }
static get watchCloudRunnerToEnd() { static get watchCloudRunnerToEnd() {
if (CloudRunnerOptions.asyncCloudRunner) { if (CloudRunnerOptions.asyncCloudRunner) {
@ -4068,8 +4068,8 @@ class Caching {
process.chdir(`${startPath}`); process.chdir(`${startPath}`);
} }
static async PullFromCache(cacheFolder, destinationFolder, cacheArtifactName = ``) { static async PullFromCache(cacheFolder, destinationFolder, cacheArtifactName = ``) {
cloud_runner_logger_1.default.log(`Pulling from cache ${destinationFolder} ${cloud_runner_1.default.buildParameters.cloudRunnerDebugSkipCache}`); cloud_runner_logger_1.default.log(`Pulling from cache ${destinationFolder} ${cloud_runner_1.default.buildParameters.skipCache}`);
if (`${cloud_runner_1.default.buildParameters.cloudRunnerDebugSkipCache}` === `true`) { if (`${cloud_runner_1.default.buildParameters.skipCache}` === `true`) {
cloud_runner_logger_1.default.log(`Skipping cache debugSkipCache is true`); cloud_runner_logger_1.default.log(`Skipping cache debugSkipCache is true`);
return; return;
} }
@ -4279,7 +4279,7 @@ class RemoteClient {
process.chdir(cloud_runner_folders_1.CloudRunnerFolders.repoPathAbsolute); process.chdir(cloud_runner_folders_1.CloudRunnerFolders.repoPathAbsolute);
await cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`); await cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`);
await cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`); await cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`);
if (!cloud_runner_1.default.buildParameters.cloudRunnerDebugSkipLFS) { if (!cloud_runner_1.default.buildParameters.skipLFS) {
await cloud_runner_system_1.CloudRunnerSystem.Run(`git lfs pull`); await cloud_runner_system_1.CloudRunnerSystem.Run(`git lfs pull`);
remote_client_logger_1.RemoteClientLogger.log(`pulled latest LFS files`); remote_client_logger_1.RemoteClientLogger.log(`pulled latest LFS files`);
node_console_1.assert(node_fs_1.default.existsSync(cloud_runner_folders_1.CloudRunnerFolders.lfsFolderAbsolute)); node_console_1.assert(node_fs_1.default.existsSync(cloud_runner_folders_1.CloudRunnerFolders.lfsFolderAbsolute));

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -79,8 +79,8 @@ class BuildParameters {
public asyncWorkflow!: boolean; public asyncWorkflow!: boolean;
public githubCheckId!: string; public githubCheckId!: string;
public triggerWorkflowOnComplete!: string[]; public triggerWorkflowOnComplete!: string[];
public cloudRunnerDebugSkipLFS!: boolean; public skipLFS!: boolean;
public cloudRunnerDebugSkipCache!: boolean; public skipCache!: boolean;
public cacheUnityInstallationOnMac!: boolean; public cacheUnityInstallationOnMac!: boolean;
public unityHubVersionOnMac!: string; public unityHubVersionOnMac!: string;
@ -183,8 +183,8 @@ class BuildParameters {
asyncWorkflow: CloudRunnerOptions.asyncCloudRunner, asyncWorkflow: CloudRunnerOptions.asyncCloudRunner,
githubCheckId: CloudRunnerOptions.githubCheckId, githubCheckId: CloudRunnerOptions.githubCheckId,
triggerWorkflowOnComplete: CloudRunnerOptions.triggerWorkflowOnComplete, triggerWorkflowOnComplete: CloudRunnerOptions.triggerWorkflowOnComplete,
cloudRunnerDebugSkipLFS: CloudRunnerOptions.cloudRunnerDebugSkipLFS, skipLFS: CloudRunnerOptions.skipLFS,
cloudRunnerDebugSkipCache: CloudRunnerOptions.cloudRunnerDebugSkipCache, skipCache: CloudRunnerOptions.skipCache,
cacheUnityInstallationOnMac: Input.cacheUnityInstallationOnMac, cacheUnityInstallationOnMac: Input.cacheUnityInstallationOnMac,
unityHubVersionOnMac: Input.unityHubVersionOnMac, unityHubVersionOnMac: Input.unityHubVersionOnMac,
}; };

View File

@ -250,11 +250,11 @@ class CloudRunnerOptions {
static get cloudRunnerDebugEnv(): boolean { static get cloudRunnerDebugEnv(): boolean {
return CloudRunnerOptions.getInput(`cloudRunnerDebugEnv`) === `true` || false; return CloudRunnerOptions.getInput(`cloudRunnerDebugEnv`) === `true` || false;
} }
static get cloudRunnerDebugSkipLFS(): boolean { static get skipLFS(): boolean {
return CloudRunnerOptions.getInput(`cloudRunnerDebugSkipLFS`) === `true` || false; return CloudRunnerOptions.getInput(`skipLFS`) === `true` || false;
} }
static get cloudRunnerDebugSkipCache(): boolean { static get skipCache(): boolean {
return CloudRunnerOptions.getInput(`cloudRunnerDebugSkipCache`) === `true` || false; return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
} }
static get watchCloudRunnerToEnd(): boolean { static get watchCloudRunnerToEnd(): boolean {

View File

@ -98,10 +98,8 @@ export class Caching {
process.chdir(`${startPath}`); process.chdir(`${startPath}`);
} }
public static async PullFromCache(cacheFolder: string, destinationFolder: string, cacheArtifactName: string = ``) { public static async PullFromCache(cacheFolder: string, destinationFolder: string, cacheArtifactName: string = ``) {
CloudRunnerLogger.log( CloudRunnerLogger.log(`Pulling from cache ${destinationFolder} ${CloudRunner.buildParameters.skipCache}`);
`Pulling from cache ${destinationFolder} ${CloudRunner.buildParameters.cloudRunnerDebugSkipCache}`, if (`${CloudRunner.buildParameters.skipCache}` === `true`) {
);
if (`${CloudRunner.buildParameters.cloudRunnerDebugSkipCache}` === `true`) {
CloudRunnerLogger.log(`Skipping cache debugSkipCache is true`); CloudRunnerLogger.log(`Skipping cache debugSkipCache is true`);
return; return;

View File

@ -145,7 +145,7 @@ export class RemoteClient {
process.chdir(CloudRunnerFolders.repoPathAbsolute); process.chdir(CloudRunnerFolders.repoPathAbsolute);
await CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`); await CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`);
await CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`); await CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`);
if (!CloudRunner.buildParameters.cloudRunnerDebugSkipLFS) { if (!CloudRunner.buildParameters.skipLFS) {
await CloudRunnerSystem.Run(`git lfs pull`); await CloudRunnerSystem.Run(`git lfs pull`);
RemoteClientLogger.log(`pulled latest LFS files`); RemoteClientLogger.log(`pulled latest LFS files`);
assert(fs.existsSync(CloudRunnerFolders.lfsFolderAbsolute)); assert(fs.existsSync(CloudRunnerFolders.lfsFolderAbsolute));