-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmd: change the prompt in lua #961
Conversation
Example old:
new:
|
Just as a reference: A filter which adds a conda environment string in the front of the lambda:
Looks like this:
|
Just for the record: I'm running my cmder with this PR since a few days and it works great: no more garbled output in |
@nullpunkt I don't think this is the same "problem" :-( This only "fixes" the problem that a subshell gets a proper commandline, not the one which is started in cmder. -> please discuss in a different issue |
b5a4f52
to
956a34f
Compare
rebased on top of current development |
This keeps the PROMPT variable as is and changes the prompt to the cmder style in the clink code. This has two advantages: * opening a cmd in a cmder session will now show the old prompt code instead of a ugly raw prompt without the replacements. This led to ugly output when a batch file echoed their content (e.g `conda build recipe/`). * when a command rewrites the prompt (e.g. an activate in a virtualenv), these command sometimes simply overwrites the PROMPT so that the cmder enhancements were not anymore in place. Now we simply don't care and overwrite it with our stuff in the clink part. This might mean that a user has to install a lua script so that e.g. conda environments are visible on the prompt.
956a34f
to
a542f4e
Compare
👍 LGTM |
Merged. Thank you for that! :) |
This keeps the PROMPT variable as is and changes the prompt to the cmder style
in the clink code.
This has two advantages:
a ugly raw prompt without the replacements. This led to ugly output when a
batch file echoed their content (e.g
conda build recipe/
).commands sometime simple overwrite the PROMPT so that the cmder enhancements
were not anymore in place. Now we simply don't care and overwrite it with our
stuff. This might mean that a user has to install a lua script so that e.g.
conda environments are visible on the prompt.
Closes: #749