import readline, rlcompleterNow completion works just like in bash. You could also set any other key than tab, but most will want exactly this.
readline.parse_and_bind("tab: complete")
If you want this to run automatically every time you run the python console, add those two lines to any file, for example into
.pythonrc in your $HOME, and then set environment variable PYTHONSTARTUP in shell startup scripts (~/.bashrc, ~/.zshrc etc) to point to that file:export PYTHONSTARTUP=$HOME/.pythonrc"
1 comments:
thanks, it works great and i <3 it :)
Post a Comment