Browse Source

add rc.py

pull/1/head
10sr 12 years ago
parent
commit
abd976e8a3
2 changed files with 14 additions and 1 deletions
  1. +2
    -1
      profile
  2. +12
    -0
      rc.py

+ 2
- 1
profile View File

@@ -9,7 +9,8 @@ export HOSTNAME
export ENV=~/.shrc export ENV=~/.shrc
export PYTHONDOCS=/usr/share/doc/python/html/ export PYTHONDOCS=/usr/share/doc/python/html/
export PYTHONPATH="${PYTHONPATH}:${HOME}/my/bin/py" export PYTHONPATH="${PYTHONPATH}:${HOME}/my/bin/py"
test -f "${HOME}/.pythonrc" && export PYTHONSTARTUP="${HOME}/.pythonrc"
test -f "${HOME}/.dotfiles/rc.py" && \
export PYTHONSTARTUP="${HOME}/.dotfiles/rc.py"
#export PYTHONPATH="~/.local/share/lib/python3.2/site-packages" #export PYTHONPATH="~/.local/share/lib/python3.2/site-packages"


__add_to_path(){ __add_to_path(){


+ 12
- 0
rc.py View File

@@ -0,0 +1,12 @@
#!/usr/bin/env python

try:
import readline
except ImportError:
print("Module readline not available.")
readline = None
else:
if "libedit" in readline.__doc__ :
readline.parse_and_bind("bind ^I rl_complete")
else :
readline.parse_and_bind("tab: complete")

Loading…
Cancel
Save