feat: add configurable Enter execution for executables and Ctrl+O terminal access#2
Merged
kooler merged 4 commits intokooler:mainfrom Apr 11, 2026
Merged
Conversation
…access - Add 'execute' option to enter_action config for running executable files - Implement Ctrl+O key binding to open terminal in current directory - Add shell return binding (Ctrl+O exits shell back to mdc) - Update help documentation and config examples - Support bash and zsh shells with temporary config files
kooler
requested changes
Apr 7, 2026
Owner
kooler
left a comment
There was a problem hiding this comment.
Good code!
Not a blocker but a thought -- perhaps would make sense to ask user for a confirmation before executing the file? to avoid incidently running something. Can be a setting that is ON by default but can be disabled if needed.
Also perhaps show something like "press any key to continue" after script is executed? so that if script quickly outputs something or fails user can see the output before it blinks back?
Author
|
Owner
|
awesome, thanks @rguziy ! |
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.
Pull Request Description
Description
This PR adds two major usability improvements to MiddayCommander, inspired by Midnight Commander:
Changes
Configuration
"execute"option toenter_actioninbehaviorconfig sectionterminalkey binding (defaults toctrl+o)Core Features
enter_action = "execute", pressing Enter on executable files runs them in foregroundFiles Modified
internal/config/config.go: Added config options and key bindingsinternal/ui/panel/panel.go: Modified Enter handling for executablesinternal/app/app.go: Added message handling and key dispatchinternal/app/commands.go: Implemented execution and terminal commandsinternal/app/keymap.go: Added terminal key bindinginternal/ui/help/help.go: Updated help documentationREADME.md: Updated features and config docsconfig.example.toml: Added new optionsConfiguration
Add to
~/.config/mdc/config.toml:Testing
Enter Execution:
enter_action = "execute"in configTerminal Access:
Help:
Motivation
Addresses user pain points with script execution convenience:
Screenshots
N/A - Terminal application, functionality can be tested via described steps.
Checklist