|
From: | L A Walsh |
Subject: | Re: [Bug Report] The Unexpected Behavior When Using ANSI Escape Code |
Date: | Tue, 22 Mar 2022 14:00:22 -0700 |
User-agent: | Thunderbird |
On 2022/03/20 02:20, Michaelll Lee wrote:
When ``PS1’’ environment variable contains the ANSI escape codes, Bash will behavior unexpectedly when Copy&Paste the content from clipboard using Ctrl+V. This unexpected behaviour could be easily reproduced in a few steps. Reproduceable steps are: 1) $ PS1='---Test \\ \e[0m ---\\$ '
---- The '\e[0m' is not an ANSI escape code. It's a directive to your terminal to do something. If you are talking to your terminal, that's above bash in the process chain, and bash can't really do anything about that. Some terminal might allow '\eexec[0mCMD' Bash can't control what your terminal emulator does as it is outside of bash.
[Prev in Thread] | Current Thread | [Next in Thread] |