3.2 Command Histories

When PyXPlot is used interactively, its command-line environment is based upon the GNU Readline Library. This means that the up and down arrow keys can be used to repeat or modify previously executed commands. Each user’s command history is stored in his homespace in a history file called .pyxplot_history, which allows PyXPlot to remember command histories between sessions. Additionally, a save command is provided, allowing the user to save his command history from the present session to a text file; this has the following syntax:

save 'output_filename.ppl'

The related history command outputs the history to the terminal. This outputs not only the history of the present session, but also commands entered in previous sessions, which can be up to several hundred lines long. It can optionally be followed by a number, to display the last $n$ commands, e.g.:

history 20