• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
setup script not being sourced from .bash_profile in xterm
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

setup script not being sourced from .bash_profile in xterm


  • Subject: setup script not being sourced from .bash_profile in xterm
  • From: Adam Mercer <email@hidden>
  • Date: Wed, 17 Mar 2010 14:37:02 -0700

Hi

I don't use xterms much but today I ran into a strange problem, the
terminal open and the following error was displayed:

bash: __git_ps1: command not found

and after every command, this is from my .bash_profile, which contains
the following:

# bash completion
if [ -f /opt/local/etc/bash_completion ]; then
  . /opt/local/etc/bash_completion
fi

# git completion
if [ -f "/opt/local/share/doc/git-core/contrib/completion/git-completion.bash"
]; then
  . /opt/local/share/doc/git-core/contrib/completion/git-completion.bash

  # prompt command
  export PROMPT_COMMAND='echo -ne "\033]0;$(__git_ps1 "(%s)")
${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/~}\007"'
else
  # prompt command
  export PROMPT_COMMAND='echo -ne
"\033]0;${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/~}\007"'
fi

so it appears that
/opt/local/share/doc/git-core/contrib/completion/git-completion.bash
is not being sourced, if I source this manually then the error is
removed and the git branch is displayed correctly in the xterm title
bar.

Any ideas on why this isn't being sourced correctly?

Cheers

Adam

PS: I see this with both stock SL X11 and 2.5.0rc1
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list      (email@hidden)

This email sent to email@hidden

  • Prev by Date: Re: XQuartz 2.5.0_rc1
  • Next by Date: Re: XQuartz 2.5.0_rc1
  • Previous by thread: Re: xnest doesn't work in 2.5.0_RC1
  • Next by thread: Bugfixes for 2.5.0_rc1
  • Index(es):
    • Date
    • Thread