fix(core): update

This commit is contained in:
2023-07-12 15:35:38 +02:00
parent bce84a0e74
commit 41237e0e5f
12 changed files with 484 additions and 214 deletions

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@shipzone/npmci',
version: '4.1.20',
version: '4.1.21',
description: 'node and docker in gitlab ci on steroids'
}

View File

@ -93,7 +93,7 @@ export class NpmciDockerManager {
}
// handle registries
await plugins.smartparam.forEachMinimatch(
await plugins.smartobject.forEachMinimatch(
process.env,
'NPMCI_LOGIN_DOCKER*',
async (envString: string) => {

View File

@ -1,11 +1,10 @@
import { logger } from '../npmci.logging.js';
import * as plugins from './mod.plugins.js';
import { ObjectMap } from '@pushrocks/lik';
import { DockerRegistry } from './mod.classes.dockerregistry.js';
export class RegistryStorage {
objectMap = new ObjectMap<DockerRegistry>();
objectMap = new plugins.lik.ObjectMap<DockerRegistry>();
constructor() {
// Nothing here
}

View File

@ -54,7 +54,7 @@ export class NpmciNpmManager {
public async prepare() {
const config = this.npmciRef.npmciConfig.getConfig();
let npmrcFileString: string = '';
await plugins.smartparam.forEachMinimatch(
await plugins.smartobject.forEachMinimatch(
process.env,
'NPMCI_TOKEN_NPM*',
(npmEnvArg: string) => {
@ -100,7 +100,7 @@ export class NpmciNpmManager {
let publishVerdaccioAsWell = false;
const config = this.npmciRef.npmciConfig.getConfig();
const availableRegistries: string[] = [];
await plugins.smartparam.forEachMinimatch(
await plugins.smartobject.forEachMinimatch(
process.env,
'NPMCI_TOKEN_NPM*',
(npmEnvArg: string) => {

View File

@ -31,7 +31,7 @@ const notUndefined = (stringArg: string) => {
*/
export let prepare = async () => {
sshInstance = new plugins.smartssh.SshInstance(); // init ssh instance
plugins.smartparam.forEachMinimatch(process.env, 'NPMCI_SSHKEY_*', evaluateSshEnv);
plugins.smartobject.forEachMinimatch(process.env, 'NPMCI_SSHKEY_*', evaluateSshEnv);
if (!process.env.NPMTS_TEST) {
sshInstance.writeToDisk();
} else {

View File

@ -7,7 +7,7 @@ const triggerValueRegex =
export let trigger = async () => {
logger.log('info', 'now running triggers');
await plugins.smartparam.forEachMinimatch(process.env, 'NPMCI_TRIGGER_*', evaluateTrigger);
await plugins.smartobject.forEachMinimatch(process.env, 'NPMCI_TRIGGER_*', evaluateTrigger);
};
const evaluateTrigger = async (triggerEnvVarArg) => {

View File

@ -2,12 +2,10 @@ import { logger } from './npmci.logging.js';
import * as plugins from './npmci.plugins.js';
import * as paths from './npmci.paths.js';
import * as smartpromise from '@pushrocks/smartpromise';
/**
* wether nvm is available or not
*/
export let nvmAvailable = smartpromise.defer<boolean>();
export let nvmAvailable = plugins.smartpromise.defer<boolean>();
/**
* the smartshell instance for npmci
*/

View File

@ -13,27 +13,29 @@ import * as servezoneInterfaces from '@servezone/interfaces';
export { servezoneInterfaces };
// @pushrocks
import * as npmextra from '@pushrocks/npmextra';
import * as projectinfo from '@pushrocks/projectinfo';
import * as qenv from '@pushrocks/qenv';
import * as smartanalytics from '@pushrocks/smartanalytics';
import * as smartdelay from '@pushrocks/smartdelay';
import * as smartfile from '@pushrocks/smartfile';
import * as smartcli from '@pushrocks/smartcli';
import * as smartgit from '@pushrocks/smartgit';
import * as smartlog from '@pushrocks/smartlog';
import * as smartlogDestinationLocal from '@pushrocks/smartlog-destination-local';
import * as smartparam from '@pushrocks/smartparam';
import * as smartpath from '@pushrocks/smartpath';
import * as smartpromise from '@pushrocks/smartpromise';
import * as smartrequest from '@pushrocks/smartrequest';
import * as smartshell from '@pushrocks/smartshell';
import * as smartsocket from '@pushrocks/smartsocket';
import * as smartssh from '@pushrocks/smartssh';
import * as smartstring from '@pushrocks/smartstring';
// @push.rocks
import * as lik from '@push.rocks/lik';
import * as npmextra from '@push.rocks/npmextra';
import * as projectinfo from '@push.rocks/projectinfo';
import * as qenv from '@push.rocks/qenv';
import * as smartanalytics from '@push.rocks/smartanalytics';
import * as smartdelay from '@push.rocks/smartdelay';
import * as smartfile from '@push.rocks/smartfile';
import * as smartcli from '@push.rocks/smartcli';
import * as smartgit from '@push.rocks/smartgit';
import * as smartlog from '@push.rocks/smartlog';
import * as smartlogDestinationLocal from '@push.rocks/smartlog-destination-local';
import * as smartobject from '@push.rocks/smartobject';
import * as smartpath from '@push.rocks/smartpath';
import * as smartpromise from '@push.rocks/smartpromise';
import * as smartrequest from '@push.rocks/smartrequest';
import * as smartshell from '@push.rocks/smartshell';
import * as smartsocket from '@push.rocks/smartsocket';
import * as smartssh from '@push.rocks/smartssh';
import * as smartstring from '@push.rocks/smartstring';
export {
lik,
npmextra,
projectinfo,
qenv,
@ -44,7 +46,7 @@ export {
smartcli,
smartlog,
smartlogDestinationLocal,
smartparam,
smartobject,
smartpath,
smartpromise,
smartrequest,