puntonim / promptastic

A fantastic prompt for Bash
http://painl.es/promptastic/
Apache License 2.0
81 stars 16 forks source link

Width mistake prompt (to wide) #28

Open maartenbeeckmans opened 4 years ago

maartenbeeckmans commented 4 years ago

With the default configuration on terminator, my prompt looks like the screenshot below.

Screenshot_20191105_204742

Screenshot is of terminator, Konsole looks the same.

The configuration in my .bashrc file is the following:

#  Promptastic is assumed to be installed in $promptastic_home
promptastic_home=~/.local/opt/promptastic

function _update_ps1() {
  PS1="$(${promptastic_home}/promptastic.py $?)"
  export PS1
}

if [ -f "${promptastic_home}/promptastic.py" ]; then
  export PROMPT_COMMAND="_update_ps1"
fi

My 'config.py` file is the following:

# This is the configuration file which helps you customize your 'promptastic' installation.
# For instructions on how to use the promptastic.py script, see the README.

# Patched fonts are special fonts best suited for terminals
# True if the current terminal is using patched fonts (available at:
# https://github.com/Lokaltog/powerline-fonts).
PATCHED_FONTS = True

# The theme defines the colors used to draw individual segments.
# Themes are collected in the `themes` directory. Their names match their file name (w/o the file
# extension .py).
THEME = 'default'

# Segments are the single elements which compose the Bash shell prompt.
# Enable or disable these segments to customize what you see on the shell prompt.
SEGMENTS = {
    # Current user's username plus @ plus machine's hostname.
    'userathost': True,

    # SSH tag when ssh-ing from another machine.
    'ssh': True,

    # Current directory path.
    'currentdir': True,

    # A padlock if the current user has read-only permissions on the current directory.
    'readonly': True,

    # A cross if the last command exited with a non-zero exit code.
    'exitcode': True,

    # Current git branch and status when the current directory is part of a git repo.
    'git': True,

    # Name of the current virtual environment (see http://www.virtualenv.org/), if any.
    'venv': True,

    # Number of running jobs, if any.
    'jobs': True,

    # Current time.
    'time': True,
}

The promptastic.py file did I not change.

Googling the mistake and reading the documentation hasn't helped me.

Another suggestion for INSTALL.md, add a path to where the config.py file will be stored. It is not mentioned here.

ebdavison commented 3 years ago

I am using simple terminal and my prompt is too wide as well

image