Browse Source

Adds auto search by commit if pattern is a sha

main
Eric Amodio 5 years ago
parent
commit
5af5af0d05
1 changed files with 13 additions and 1 deletions
  1. +13
    -1
      src/git/gitService.ts

+ 13
- 1
src/git/gitService.ts View File

@ -3051,7 +3051,19 @@ export class GitService implements Disposable {
let match = searchMessageOperationRegex.exec(search);
if (match != null && match[1] !== '') {
this.parseSearchMessageOperations(match[1], operations);
[, value] = match;
if (GitService.isSha(value)) {
let values = operations.get('commit:');
if (values === undefined) {
values = [value];
operations.set('commit:', values);
} else {
values.push(value);
}
} else {
this.parseSearchMessageOperations(value, operations);
}
}
do {

Loading…
Cancel
Save