4 ms·
Moreover, editor allows to switch to console via Ctrl-O, which turns it into an simple IDE for console programs: edit code, Ctrl-O, run program, Ctrl-C Ctrl-O,
by oneshtein 3y ago
Moreover, editor allows to switch to console via Ctrl-O, which turns it into an simple IDE for console programs: edit code, Ctrl-O, run program, Ctrl-C Ctrl-O, repeat.
- amne 3y agoI always thought the C-o subshell needed a status bar or something. Not once did I find myself launching mc again because I forgot it was already running. Luckily it warns you when launched from the subshell.
- JNRowe 3y agomc sets $MC_SID in the subshell, so you can query that in your prompt to mark prompts running under mc. Another option might be to bind F10 to start mc, so that it acts as a toggle whether in mc or in a non-mc shell. You'd need to wrap a zle widget in zsh, or add a '$if Bash' guard to your inputrc with bash.
- shmerl 3y agoWith neovim it's easy also with: * Ctrl+Z * Do something in the shell * fg
- machomaster 3y agoIt's not neovim, it's the general Unix shell functionality working with all programs.
- shmerl 3y agoSure, but it's a useful pattern.