Dump interpreter history?
John Gordon
gordon at panix.com
Fri Mar 25 17:25:51 EDT 2011
In <mailman.1266.1301087057.1189.python-list at python.org> "Ken D'Ambrosio" <ken at jots.org> writes:
> Hey, all. A co-worker asked me a question, and I've got no idea how (or
> if) it can be done. Bottom line: he'd like to save off the text from an
> interpreter session, his thinking being that you've already tried to get
> what you want, and now you just need to gussy it up in an editor.
If you're running on a unix system, run the "script" command before
starting the interpreter. Then when you're finished with the interpreter,
type "exit" to end the script session. This will create a file named
"typescript" containing all of the input and output which occurred.
--
John Gordon A is for Amy, who fell down the stairs
gordon at panix.com B is for Basil, assaulted by bears
-- Edward Gorey, "The Gashlycrumb Tinies"
More information about the Python-list
mailing list