Permalink
Browse files

add python interpreter tab completion

  • Loading branch information...
cpdean committed May 5, 2014
1 parent 94df808 commit 06902ddbc9025a51051013c83a7e9bbb8b5cf351
Showing with 11 additions and 0 deletions.
  1. +3 −0 .bashrc
  2. +8 −0 .pythonrc
View
@@ -122,6 +122,9 @@ if [ -f ~/.dotfiles/.git-completion.bash ]; then
. ~/.dotfiles/.git-completion.bash
fi
+# tab completion for python, and maybe other stuff
+export PYTHONSTARTUP=~/.pythonrc
+
# virtualenvwrapper stuff
export WORKON_HOME=$HOME/.virtualenvs
export PROJECT_HOME=$HOME/dev
View
@@ -0,0 +1,8 @@
+# tab completion
+try:
+ import readline
+except ImportError:
+ print("readline not available. setting tab completion for python not possible")
+else:
+ import rlcompleter
+ readline.parse_and_bind("tab:complete")

0 comments on commit 06902dd

Please sign in to comment.