The command-line version of SeqNinja runs within a command shell (terminal) window. SeqNinja is launched in different ways, depending whether you’d like to run in “batch mode” or “interactive mode.” All scripting language commands can be used in either mode.
- In batch mode, you run a command script stored in a file. Batch mode is useful for complex scripts and for repeatability. The script file provides a record of the operations performed. An example of a script for batch mode use is shown below:
- In interactive mode, you enter and run commands one-at-a-time, directly in the SeqNinja command shell. Interactive mode is useful for experimentation and brief, ad hoc commands. A sample interactive section is illustrated below.
Running SeqNinja in batch mode:
From within a Command Prompt window (Win) or Terminal window (Mac), type “seqninja” followed by the name of a script, or by another command-line option.
If running a script, you will first need to prepare a file of scripting commands using the SeqNinja application or any text editor, and then save the file with the extension .star (e.g., myfile.star). In the command shell, enter the command seqninja filename.star
and press Enter. This will run all the scripting commands in order of their appearance in the text file.
Running SeqNinja in interactive mode:
Launch the SeqNinja command shell in either of these ways:
- From within a Command Prompt window (Win) or Terminal window (Mac), type
seqninja
.
- (Win only) From within a file explorer, double click on the SeqNinja executable (located in the SeqNinjaCL subdirectory).
Once the SeqNinja shell has been launched, you will see a double colon (i.e. ::
) command prompt. You are now ready to begin entering scripting commands and pressing Enter to perform each operation.
Notification of scripting errors:
If there are issues with a script, SeqNinja will attempt to flag these prior to executing the script. SeqNinja checks the script for issues such as:
- Input files that do not exist, are not readable by the user, or are not created by the script before they’re used as input.
- Output files that are not writable by the user.
- Undefined variables.
- Unknown functions.
- Missing or unexpected function arguments.
Need more help with this?
Contact DNASTAR