Command History

Command History

The Command History lists previously used commands. The commands can be re-executed and/or saved to a file. The Command History can be opened from the pulldown menu marked by a black triangle to the right of the Command Line. The menu also shows the most recently entered commands. Commands are shown as entered even if they failed to execute due to mistyping or incorrect syntax.

In the Command History, individual commands or blocks of commands may be chosen (highlighted) using the left mouse button. Ctrl-click adds to an existing choice rather than replacing it. To choose a block of commands without dragging, click on the first (or last) and then Shift-click on the last (or first) in the desired block. The choice of a single command, but not a block of commands, can be moved up and down the list using the keyboard up arrow and down arrow or Ctrl-p and Ctrl-n. In the figure, three commands are chosen.

Record... brings up a dialog for saving or appending commands to a file. The chosen commands or all commands in the history can be saved, as Chimera commands or their Python translations.

Execute executes the chosen commands in the order shown; double-clicking an individual command executes that command. Delete removes the chosen commands from the history.

Close dismisses the Command History window; Help opens this manual page in a browser window.

Recently used commands are saved upon exiting from Chimera and will appear in the Command History of the next session that uses the same preferences file. How many commands to remember between sessions is specified in the Command Line preferences.

Python Translations of Commands

A file containing the Python translations of commands cannot be executed in Chimera until statements to import any necessary modules have been added. In some cases, adding

import Midas
to the beginning of the file will be sufficient; however, additional modules may need to be imported, depending on the particular commands included and any further code that is added to the file.


UCSF Computer Graphics Laboratory / July 2008