Possible duplicate:How to save an interactive Python session?
Is it possible, and if so, how can I save the code that I wrote in an IPython session?
Optimally, I would only output code that works without errors, but exporting the code will still be long. I suppose.
%save my_useful_session 10-20 23
to save input strings from 10 to 20 and from 23 to my_useful_session.py
my_useful_session.py