diff options
| author | Andre Hartmann <[email protected]> | 2025-11-24 12:37:27 +0100 |
|---|---|---|
| committer | André Hartmann <[email protected]> | 2025-12-01 08:05:05 +0000 |
| commit | 7eb09fd032f354a3424d009b9a1f791b72f42bec (patch) | |
| tree | cb68f2b020d3dcbb9bd9fba62c05680787e4d2d2 /src/plugins/git/gitclient.cpp | |
| parent | 66793e2e6a551eea4b963bbafdfce18895eba6d5 (diff) | |
VCS: Print error when diff or log fail
Change-Id: I915e42033f01b83a3ad32339dcaef3d4ed2572f6
Reviewed-by: Orgad Shaneh <[email protected]>
Reviewed-by: Marcus Tillmanns <[email protected]>
Diffstat (limited to 'src/plugins/git/gitclient.cpp')
| -rw-r--r-- | src/plugins/git/gitclient.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/plugins/git/gitclient.cpp b/src/plugins/git/gitclient.cpp index d3bd748480e..1054da6a612 100644 --- a/src/plugins/git/gitclient.cpp +++ b/src/plugins/git/gitclient.cpp @@ -251,12 +251,17 @@ GitDiffEditorController::GitDiffEditorController(IDocument *document, VcsOutputWindow::appendCommand(process.workingDirectory(), process.commandLine()); }; const auto onDiffDone = [diffInputStorage](const Process &process) { - *diffInputStorage = process.cleanedStdOut(); + if (process.result() == ProcessResult::FinishedWithSuccess) { + *diffInputStorage = process.cleanedStdOut(); + } else { + VcsOutputWindow::instance()->appendError(process.workingDirectory(), + process.cleanedStdErr()); + } }; const Group root { diffInputStorage, - ProcessTask(onDiffSetup, onDiffDone, CallDone::OnSuccess), + ProcessTask(onDiffSetup, onDiffDone, CallDone::Always), postProcessTask(diffInputStorage) }; setReloadRecipe(root); |
