Path: csiph.com!goblin1!goblin.stu.neva.ru!usenet.stanford.edu!not-for-mail From: =?ISO-8859-1?Q?=C1ngel?= Newsgroups: gnu.bash.bug Subject: Re: [PATCH] Add active mark, face support; activate mark on paste Date: Thu, 16 Apr 2020 02:41:47 +0200 Lines: 43 Approved: bug-bash@gnu.org Message-ID: References: <875c423e-0420-78d2-af4b-dfb168432e2d@case.edu> <1586997707.1070.15.camel@16bits.net> NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Trace: usenet.stanford.edu 1586997715 12038 209.51.188.17 (16 Apr 2020 00:41:55 GMT) X-Complaints-To: action@cs.stanford.edu To: bug-bash@gnu.org Envelope-to: bug-bash@gnu.org In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 199.195.249.9 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Mailman-Original-Message-ID: <1586997707.1070.15.camel@16bits.net> X-Mailman-Original-References: <875c423e-0420-78d2-af4b-dfb168432e2d@case.edu> Xref: csiph.com gnu.bash.bug:16143 On 2020-04-11 at 18:04 +0200, gentoo_eshoes wrote: > $ echo ${PS1@A} > declare -x PS1=3D$'\\\n-----------\\n\\\n\\[\\a\\]\\\n\\[\\e[1;37m\ > \e[42m\\]\\u@\\H\\[\\e[0m\\] \\\n\\[\\033[1;30m\\]$(date "+%Y/%m/%d % > H:%M:%S")\\[\\033[0m\\] \\\n\\[\\e[0;37m\\]\\s\\V t:\\l j:\\j \\\nd: > ${SHLVL} pp:${PPID} p:$$ ut`cat /proc/uptime | cut -f1 -d.`\\[\\e[0m\ > \]\\n\\\n\\[\\e[0;37m\\]!\\!\\[\\e[0m\\] \\\n\\[\\033[0;36m\\]\\#\\[\ > \033[0m\\] \\\n$(evalexitcode "${__earlyec[@]}" ) \\\n\\[\\e[0m\ > \]$(uname -r) $(uname -v)\n$(ps_lepath "\\w")\\[ \\033];\\w\\a\\]\n\ > \[\\e[1;32m\\]\\$\\[\\e[0m\\] \\\n' That was an=E2=80=A6 'interesting' prompt. Note that there are several subprocesses that you could easily avoid: $(date "+%Y/%m/%d %H:%M:%S") is equivalent to \D{%Y/%m/%d %H:%M:%S} `cat /proc/uptime | cut -f1 -d.` this could be simplified to `cut -f1 -d. = /proc/uptime` it may be replaced with just builtins by `uptime=3D$(