Results 1 to 3 of 3

Thread: Misbehaving Bash Prompt

  1. #1
    Join Date
    Jun 2009
    Location
    Little Rock, Arkansas
    Beans
    190
    Distro
    Ubuntu 12.04 Precise Pangolin

    Smile Misbehaving Bash Prompt

    I added this command to my .bashrc file to add color to my prompt
    and to simplify its path portion to the lowest level directory,
    Code:
    `PS1='\e[1;31m\u@\h:\W\$\e[m '
    and my bash prompt comes up as expected.
    But occasionally, when I enter a command, part of that command
    becomes part of my prompt!
    If the following is a prompt and command,
    Code:
    prompt$ command
    then my prompt might come back as
    Code:
    prompt$ com
    What's causing this strange behavior?
    Please let me know if you need to see more of my .bashrc file.

    Thanks for your help and grateful for this forum, Randy
    Last edited by Randy Schilling; November 6th, 2012 at 03:09 AM.

  2. #2
    Join Date
    Nov 2012
    Beans
    18

    Re: Misbehaving Bash Prompt

    Try this instead.

    Code:
    export "PS1='\e[1;31m\u@\h:\W\$\e[m "

  3. #3
    Join Date
    Jun 2009
    Location
    Little Rock, Arkansas
    Beans
    190
    Distro
    Ubuntu 12.04 Precise Pangolin

    Smile Re: Misbehaving Bash Prompt

    Yes, thanks thanks thanks!

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •