pastebin - collaborative debugging tool
kpaste.net RSS


bash_completion.sh 12.04
Posted by Anonymous on Sat 14th Mar 2015 20:11
raw | new post
view followups (newest first): bash_completion.sh 14.04 by Anonymous

  1. ## /etc/profile.d/bash_completion.sh as it is in Ubuntu 12.04
  2. # Check for interactive bash and that we haven't already been sourced.
  3. [ -z "$BASH_VERSION" -o -z "$PS1" -o -n "$BASH_COMPLETION" ] && return
  4.  
  5. # Check for recent enough version of bash.
  6. bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.}
  7. if [ $bmajor -gt 3 ] || [ $bmajor -eq 3 -a $bminor -ge 2 ]; then
  8.     if shopt -q progcomp && [ -r /etc/bash_completion ]; then
  9.         # Source completion code.
  10.         . /etc/bash_completion
  11.     fi  
  12. fi
  13. unset bash bmajor bminor

Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.

Syntax highlighting:

To highlight particular lines, prefix each line with {%HIGHLIGHT}




All content is user-submitted.
The administrators of this site (kpaste.net) are not responsible for their content.
Abuse reports should be emailed to us at