• Travis Cross's avatar
    Add back terminal detection for old libedits · 4f54f912
    Travis Cross 提交于
    Using the system libedit means that libedit will again make absolute
    movements on certain kinds of terminals.  Older versions of libedit
    without EL_PROMPT_ESC miscalculate the length of the prompt.
    Combined, this results in the cursor ending up in the wrong place.
    
    We knew this was a possibility when we moved to system libedit, and
    we're OK with it.  We certainly lived without this fancy prompt
    feature for a long time.
    
    This change puts back in place detection of the terminal type when
    EL_PROMPT_ESC isn't available.  On these older versions of libedit,
    we'll only enable the fancy features when we know that libedit will
    only make relative movements and not tickle the bug.
    
    This partially reverts commit:
    b9b77bd6
    4f54f912
fs_cli.c 46.2 KB