update to deno

This commit is contained in:
2025-12-13 13:27:51 +00:00
parent dba2e2ae68
commit 9ad5222b95
25 changed files with 196 additions and 225 deletions

View File

@@ -22,20 +22,20 @@ export class SzciGitManager {
await this.mirror();
break;
default:
logger.log('error', `npmci git -> action >>${action}<< not supported!`);
logger.log('error', `szci git -> action >>${action}<< not supported!`);
}
} else {
logger.log('info', `npmci git -> cli arguments invalid! Please read the documentation.`);
logger.log('info', `szci git -> cli arguments invalid! Please read the documentation.`);
}
};
public mirror = async () => {
const githubToken = Deno.env.get("NPMCI_GIT_GITHUBTOKEN");
const githubUser = Deno.env.get("NPMCI_GIT_GITHUBGROUP") || this.szciRef.npmciEnv.repo.user;
const githubRepo = Deno.env.get("NPMCI_GIT_GITHUB") || this.szciRef.npmciEnv.repo.repo;
const githubToken = Deno.env.get("SZCI_GIT_GITHUBTOKEN");
const githubUser = Deno.env.get("SZCI_GIT_GITHUBGROUP") || this.szciRef.szciEnv.repo.user;
const githubRepo = Deno.env.get("SZCI_GIT_GITHUB") || this.szciRef.szciEnv.repo.repo;
if (
this.szciRef.npmciConfig.getConfig().projectInfo.npm.packageJson.private === true ||
this.szciRef.npmciConfig.getConfig().npmAccessLevel === 'private'
this.szciRef.szciConfig.getConfig().projectInfo.npm.packageJson.private === true ||
this.szciRef.szciConfig.getConfig().npmAccessLevel === 'private'
) {
logger.log(
'warn',
@@ -64,7 +64,7 @@ export class SzciGitManager {
// remove old mirrors
await bashNoError('git remote rm mirror');
} else {
logger.log('error', `cannot find NPMCI_GIT_GITHUBTOKEN env var!`);
logger.log('error', `cannot find SZCI_GIT_GITHUBTOKEN env var!`);
Deno.exit(1);
}
};