Skip to content
Snippets Groups Projects
Commit a91c7b4e authored by michael.minelli's avatar michael.minelli
Browse files

AssignmentCheck => Update log function

parent 3563356a
No related branches found
No related tags found
No related merge requests found
Pipeline #28926 passed
......@@ -32,14 +32,18 @@ class AssignmentCheckCommand extends CommanderCommand {
let spinner: ora.Ora;
if ( verbose ) {
let buildPhase: boolean = true;
assignmentValidator.events.on('logs', (log: string, _error: boolean, displayable: boolean, _currentStep: string, currentSubStep: string) => {
let buildPhase: boolean | undefined = undefined;
assignmentValidator.events.on('logs', (log: string, error: boolean, displayable: boolean, _currentStep: string, currentSubStep: string) => {
for ( const line of log.split('\n') ) {
if ( currentSubStep == 'COMPOSE_RUN' && buildPhase && line != '' && !line.startsWith('#') ) {
if ( displayable && buildPhase == undefined && line.startsWith('#') ) {
buildPhase = true;
}
if ( currentSubStep == 'COMPOSE_RUN' && buildPhase === true && line != '' && !line.startsWith('#') ) {
buildPhase = false;
}
if ( displayable && (options.superVerbose || !buildPhase) ) {
if ( displayable && (options.superVerbose || buildPhase === false) ) {
console.log(line);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment