(branch: string)
| 1176 | } |
| 1177 | |
| 1178 | async rebaseBranch(branch: string) { |
| 1179 | try { |
| 1180 | // Get the diff between the default branch the published branch |
| 1181 | const { base_commit: baseCommit, commits } = await this.getDifferences( |
| 1182 | this.branch, |
| 1183 | await this.getHeadReference(branch), |
| 1184 | ); |
| 1185 | // Rebase the branch based on the diff |
| 1186 | const rebasedHead = await this.rebaseCommits(baseCommit, commits); |
| 1187 | return rebasedHead; |
| 1188 | } catch (error) { |
| 1189 | console.error(error); |
| 1190 | throw error; |
| 1191 | } |
| 1192 | } |
| 1193 | |
| 1194 | async setPullRequestStatus(pullRequest: GitHubPull, newStatus: string) { |
| 1195 | const labels = [ |
no test coverage detected