From 21680813720b4dc2c1e24f8c0744f1a6d6eb6b5d Mon Sep 17 00:00:00 2001 From: pvincent Date: Wed, 31 Jan 2024 17:04:04 +0400 Subject: [PATCH] nested miaou prompt --- bash.bashrc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bash.bashrc b/bash.bashrc index 021e73f..8baea00 100644 --- a/bash.bashrc +++ b/bash.bashrc @@ -68,7 +68,7 @@ __prompt_command() { if [[ -n ${container_hostname:-} ]]; then PS1+="${Gra}[LXC:${R}" - local host=$container_hostname + local host=$(builtin echo $container_hostname | tr ' ' ':') case ${host:0:4} in 'beta') PS1+="${Yel}" @@ -154,7 +154,8 @@ __vte_osc7() { VTE_INFO="${HOSTNAME:-}" if [[ -n ${container_hostname:-} ]]; then - VTE_INFO="${container_hostname}" + local host=$(builtin echo $container_hostname | tr ' ' ':') + VTE_INFO="$host:$HOSTNAME" fi printf "\[\033]7;file://%s%s\a\]" "${VTE_INFO}" "$(__vte_urlencode "${PWD}")"