update branch names for reporting checks

This commit is contained in:
Yann Braga 2022-11-16 12:51:24 +01:00
parent f707d71c90
commit fd15defb0d
2 changed files with 4 additions and 3 deletions

View File

@ -189,7 +189,7 @@ commands:
when: on_fail
command: git fetch --unshallow
- discord/status:
only_for_branches: main,next,alpha
only_for_branches: main,next,next-release,latest-release
fail_only: true
failure_message: $(yarn get-report-message << pipeline.parameters.workflow >> << parameters.template >>)
jobs:

View File

@ -3,7 +3,7 @@ import { command } from 'execa';
import { readJson } from 'fs-extra';
import { join } from 'path';
type Branch = 'main' | 'next' | 'alpha';
type Branch = 'main' | 'next' | 'alpha' | 'next-release' | 'latest-release';
type Workflow = 'merged' | 'daily';
const getFooter = async (branch: Branch, workflow: Workflow, job: string) => {
@ -11,7 +11,8 @@ const getFooter = async (branch: Branch, workflow: Workflow, job: string) => {
return `\n\nThis might not necessarily be a bug, it could be a visual diff that you have to review and approve. Please check it!`;
}
if (branch === 'alpha') {
// The CI workflows can run on release branches and we should display the version number
if (branch === 'next-release' || branch === 'latest-release') {
const packageJson = await readJson(join(__dirname, '..', 'code', 'package.json'));
// running in alpha branch we should just show the version which failed