Show loading status while preparing custom command prompts#5733
Open
ileadall42 wants to merge 2 commits into
Open
Show loading status while preparing custom command prompts#5733ileadall42 wants to merge 2 commits into
ileadall42 wants to merge 2 commits into
Conversation
added 2 commits
June 27, 2026 08:48
Prompt templates can run user commands before the final custom command starts. When those commands are slow, lazygit previously looked idle because the existing command-level loading text only covered the final command execution. Wrap prompt resolution, suggestion loading, and menuFromCommand generation with the prompt's loading text so users get progress feedback during each synchronous prompt preparation step.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
loadingTextsupport to custom command prompts while resolving slow prompt values, loading suggestions, and generatingmenuFromCommandoptions.output: commitMessagePanel, which sends custom command stdout into Lazygit's native commit message panel as the initial commit message.Motivation
Custom commands can use slow commands to generate prompt values or commit messages. Before this change, users had no visible feedback while those prompt-generation commands were running, and custom commands could not hand generated commit text back to Lazygit's native commit summary/body UI.
This keeps the flow inside Lazygit and reuses the existing commit panel and commit logic instead of introducing a separate commit UI.
Validation
go test -count=1 ./pkg/gui/services/custom_commands ./pkg/configgo test pkg/integration/clients/*.go -run 'TestIntegration/custom_commands/'env -u NO_COLOR TERM=xterm-256color go test ./... -short./scripts/golangci-lint-shim.sh run