diff --git a/CHANGELOG.md b/CHANGELOG.md index 92a13a7..9df1081 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,10 +8,19 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p ### Changed +- Improved Rebase editor — better performance and user experience + - Changes the header and footer to always be visible + - Shows the _Commit Details_ view on commit selection + - Adds full (multiline) commit message + - Adds the `f` fixup shortcut key to UI + - Ensures that large rebases show rich commit details - Changes the _Home_ view to always be available ### Fixed +- Fixes [#2141](https://github.com/gitkraken/vscode-gitlens/issues/2141) - GitLens's rebase UI randomly fails loading interactive rebase when performed outside of VSC +- Fixes [#1732](https://github.com/gitkraken/vscode-gitlens/issues/1732) - Phantom rebase-merge directory (`rm -rf ".git/rebase-merge"`) +- Fixes [#1652](https://github.com/gitkraken/vscode-gitlens/issues/1652) - Closing interacteractive rebase editor after "git rebase --edit" aborts rebase-in-progress - Fixes [#1549](https://github.com/gitkraken/vscode-gitlens/issues/1549) - Fetch does not work when local branch name differs from remote branch name - Fixes [#2292](https://github.com/gitkraken/vscode-gitlens/issues/2292) - Push button in BranchTrackingStatusNode of non-current branch does not trigger "Push force" - Fixes [#1488](https://github.com/gitkraken/vscode-gitlens/issues/1488) - Open Folder History not working with non-English language pack diff --git a/src/env/node/git/git.ts b/src/env/node/git/git.ts index d7b7679..6a273fe 100644 --- a/src/env/node/git/git.ts +++ b/src/env/node/git/git.ts @@ -15,6 +15,7 @@ import { GitLogParser } from '../../../git/parsers/logParser'; import { GitReflogParser } from '../../../git/parsers/reflogParser'; import { GitTagParser } from '../../../git/parsers/tagParser'; import { Logger } from '../../../logger'; +import { join } from '../../../system/iterable'; import { dirname, isAbsolute, isFolderGlob, joinPaths, normalizePath, splitPath } from '../../../system/path'; import { getDurationMilliseconds } from '../../../system/string'; import { compare, fromString } from '../../../system/version'; @@ -1191,17 +1192,18 @@ export class Git { limit?: number; ordering?: 'date' | 'author-date' | 'topo' | null; skip?: number; - useShow?: boolean; + shas?: Set; }, ) { - if (options?.useShow) { + if (options?.shas != null) { + const stdin = join(options.shas, '\n'); return this.git( - { cwd: repoPath }, + { cwd: repoPath, stdin: stdin }, 'show', + '--stdin', '--name-status', `--format=${GitLogParser.defaultFormat}`, '--use-mailmap', - ...search, ); } diff --git a/src/env/node/git/localGitProvider.ts b/src/env/node/git/localGitProvider.ts index 31a78b3..3114cfb 100644 --- a/src/env/node/git/localGitProvider.ts +++ b/src/env/node/git/localGitProvider.ts @@ -4231,7 +4231,14 @@ export class LocalGitProvider implements GitProvider, Disposable { return cancelled ? ref : resolved ?? ref; } - @log() + @log({ + args: { + 1: s => + `[${s.matchAll ? 'A' : ''}${s.matchCase ? 'C' : ''}${s.matchRegex ? 'R' : ''}]: ${ + s.query.length > 500 ? `${s.query.substring(0, 500)}...` : s.query + }`, + }, + }) async richSearchCommits( repoPath: string, search: SearchQuery, @@ -4252,11 +4259,11 @@ export class LocalGitProvider implements GitProvider, Disposable { args.push(...files); } - const data = await this.git.log__search(repoPath, args, { + const data = await this.git.log__search(repoPath, shas?.size ? undefined : args, { ordering: configuration.get('advanced.commitOrdering'), ...options, limit: limit, - useShow: Boolean(shas?.size), + shas: shas, }); const log = GitLogParser.parse( this.container, diff --git a/src/git/gitProviderService.ts b/src/git/gitProviderService.ts index a712832..1e55919 100644 --- a/src/git/gitProviderService.ts +++ b/src/git/gitProviderService.ts @@ -2232,7 +2232,14 @@ export class GitProviderService implements Disposable { return provider.resolveReference(path, ref, pathOrUri, options); } - @log() + @log({ + args: { + 1: s => + `[${s.matchAll ? 'A' : ''}${s.matchCase ? 'C' : ''}${s.matchRegex ? 'R' : ''}]: ${ + s.query.length > 500 ? `${s.query.substring(0, 500)}...` : s.query + }`, + }, + }) async richSearchCommits( repoPath: string | Uri, search: SearchQuery, diff --git a/src/webviews/apps/rebase/rebase.html b/src/webviews/apps/rebase/rebase.html index 335dfbd..feae4d2 100644 --- a/src/webviews/apps/rebase/rebase.html +++ b/src/webviews/apps/rebase/rebase.html @@ -4,7 +4,7 @@ - +

GitLens Interactive Rebase

@@ -25,35 +25,40 @@
-
    -
    - pPick - rReword - eEdit - sSquash - dDrop - alt ↑Move Up - alt ↓Move Down - /Search +
    +
      -
      -
      - - +
      +
      + pPick + rReword + eEdit + sSquash + fFixup + dDrop + alt ↑Move Up + alt ↓Move Down + /Search
      -
      - - +
      +
      + + +
      +
      + + +
      -
      +
      #{endOfBody}