Dump interpreter history?
John Gordon
gordon at panix.com
Mon Apr 11 18:15:47 EDT 2011
In <mailman.1278.1301104317.1189.python-list at python.org> Tim Chase <python.list at tim.thechases.com> writes:
> > import readline
> > readline.write_history_file([filename])
> Just to clarify (I thought Daniel's answer was so easy it must
> have misinterpreted the OP's request), that's a single string as
> a filename, not a list containing a filename. I tried
In most documentation, square brackets indicate that the enclosed item is
optional; the brackets are not meant to be used literally.
Therefore, this text:
readline.write_history_file([filename])
says "You can call write_history_file() with no arguments at all, or
with one argument which is the name of the file to be written."
--
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