This commit is contained in:
joaorreis
2018-12-17 14:47:35 +00:00
parent 8c09d4f476
commit 6dbf6b5857
2 changed files with 15 additions and 4 deletions

View File

@@ -1197,7 +1197,7 @@ export class Repository {
}
}
async pull(rebase?: boolean, remote?: string, branch?: string): Promise<void> {
async pull(rebase?: boolean, remote?: string, branch?: string, cancellationToken?: CancellationToken): Promise<void> {
const args = ['pull', '--tags'];
if (rebase) {
@@ -1210,7 +1210,7 @@ export class Repository {
}
try {
await this.run(args);
await this.run(args, { cancellationToken });
} catch (err) {
if (/^CONFLICT \([^)]+\): \b/m.test(err.stdout || '')) {
err.gitErrorCode = GitErrorCodes.Conflict;