diff --git a/dev-infra/pullapprove/group.ts b/dev-infra/pullapprove/group.ts index 4a4630ad21..247ea4054a 100644 --- a/dev-infra/pullapprove/group.ts +++ b/dev-infra/pullapprove/group.ts @@ -72,13 +72,17 @@ export class PullApproveGroup { } else if (condition.match(CONDITION_TYPES.ATTR_LENGTH)) { // Currently a noop as we do not take any action on this condition type. } else { - const errMessage = `Unrecognized condition found, unable to parse the following condition: \n\n` + - `From the [${groupName}] group:\n` + - ` - ${condition}` + - `\n\n` + - `Known condition regexs:\n` + - `${Object.entries(CONDITION_TYPES).map(([k, v]) => ` ${k} - ${v}`).join('\n')}` + - `\n\n`; + const errMessage = + `Unrecognized condition found, unable to parse the following condition: \n\n` + + `From the [${groupName}] group:\n` + + ` - ${condition}` + + `\n\n` + + `Known condition regexs:\n` + + `${Object.entries(CONDITION_TYPES).map(([k, v]) => ` ${k} - $ { + v + } + `).join('\n')}` + + `\n\n`; console.error(errMessage); process.exit(1); } diff --git a/dev-infra/pullapprove/verify.ts b/dev-infra/pullapprove/verify.ts index 5566e78734..f92fd073a3 100644 --- a/dev-infra/pullapprove/verify.ts +++ b/dev-infra/pullapprove/verify.ts @@ -9,10 +9,11 @@ import {readFileSync} from 'fs'; import * as path from 'path'; import {cd, exec, set} from 'shelljs'; +import {getRepoBaseDir} from '../utils/config'; + import {PullApproveGroup} from './group'; import {logGroup, logHeader} from './logging'; import {parsePullApproveYaml} from './parse-yaml'; -import {getRepoBaseDir} from '../utils/config'; export function verify() { // Exit early on shelljs errors