Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit da639ffc authored by Ricardo Cerqueira's avatar Ricardo Cerqueira
Browse files

envsetup: More PROMPT_COMMAND

* Get rid of ANDROID_NO_PROMPT_COMMAND, the pre-existing STAY_OFF_MY_LAWN
does the same thing
* Remove any pre-existing android prefixes to avoid accumulation
scenarios in consecutive builds (i.e., multiple build identification
strings in hardstatus)

Change-Id: I86661e066e18ea6ad0c742fa1dc6555780fa5441
parent da54df52
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -240,6 +240,10 @@ function settitle()
            # Prompts exist, but no hardstatus
            PROMPT_COMMAND="echo -ne \"\033]0;${USER}@${HOSTNAME}: ${PWD}\007\";${PROMPT_COMMAND}"
        fi
        if [ ! -z "$ANDROID_PROMPT_PREFIX" ]; then
            PROMPT_COMMAND=$(echo $PROMPT_COMMAND | sed -e 's/$ANDROID_PROMPT_PREFIX //g')
        fi

        if [ -z "$apps" ]; then
            ANDROID_PROMPT_PREFIX="[${arch}-${product}-${variant}]"
        else
@@ -248,10 +252,8 @@ function settitle()
        export ANDROID_PROMPT_PREFIX

        # Inject build data into hardstatus
	if [ -z "$ANDROID_NO_PROMPT_COMMAND" ]; then
        export PROMPT_COMMAND=$(echo $PROMPT_COMMAND | sed -e 's/\\033]0;\(.*\)\\007/\\033]0;$ANDROID_PROMPT_PREFIX \1\\007/g')
    fi
    fi
}

function addcompletions()