refactor: move backport data generation to configs parser

This commit is contained in:
Andrea Lamparelli 2023-07-27 11:26:39 +02:00
parent e13d1fbf00
commit 10a46551ee
15 changed files with 238 additions and 310 deletions

View file

@ -38,4 +38,5 @@ import { BackportPullRequest, GitPullRequest } from "@bp/service/git/git.types";
* @returns {Promise<string>} the pull request url
*/
createPullRequest(backport: BackportPullRequest): Promise<string>;
}

View file

@ -13,8 +13,8 @@ export interface GitPullRequest {
labels: string[],
targetRepo: GitRepository,
sourceRepo: GitRepository,
nCommits?: number, // number of commits in the pr
commits?: string[], // merge commit or last one
nCommits: number, // number of commits in the pr
commits: string[], // merge commit or last one
branchName?: string,
}
@ -34,7 +34,8 @@ export interface BackportPullRequest {
reviewers: string[], // pr list of reviewers
assignees: string[], // pr list of assignees
labels: string[], // pr list of assigned labels
branchName?: string,
comments: string[], // pr list of additional comments
// branchName?: string,
}
export enum GitClientType {

View file

@ -141,7 +141,6 @@ export default class GitLabClient implements GitClient {
return mr.web_url;
}
/**
* Retrieve a gitlab user given its username
* @param username