Is it possible to have different command line prompt in pure bash and mc? So, sometime i have mc started, but but panels switched off (Ctrl+O), and when i return back to the terminal after some period of time I forget is mc started or not, and some times try to start mc again, or try to switch on panels, when mc is not started.

So, what I try to do: in normal mode path should look like:


when in mc mode something like:

PS1=mc \u:\w$

So, the question is: how can i make different PS1 prompts for mc and pure bash?


man mc says:

If you are using bash you can specify startup commands for the subshell in your ~/.local/share/mc/bashrc file and special keyboard maps in the ~/.local/share/mc/inputrc file. tcsh users may specify startup commands in the ~/.local/share/mc/tcshrc file.

So you can set up your different version of PS1 variable inside ~/.local/share/mc/bashrc.

| improve this answer | |
  • found it, thanks. shame on me: i missed it in man, and i've tried already ~/.config/mc, ~/.mc and bunch of other places, but i missed only one right place for "shell specific settings" – radistao Sep 13 '16 at 9:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.