A feature that I tend to use quite often in the ipython shell is auto-completion of partially typed command from the history. At the repl, one can type only the first few letters of the command and hit the up to find in the command history the last executed command that begin with the partially typed string.
Is this feature available in emacs? by pressing C-up, the python command history can be recalled, but it does not use the partially typed command?
You can get completion for partially typed commands using
comint-previous-matching-input-from-input
andcomint-next-matching-input-from-input
.By default they are bind to C-c M-r and C-c M-s.
If you have typed
l = 1
and now you can typel
and press C-c M-r to get previous completion.If you dont want to use C-c M-r and like to use up arrow, you put this code in your config.
Now you can use up/down arrows for it.