1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
use crate::errors::*;

use crate::shell::Shell;


#[inline]
fn help(name: &str, descr: &str) {
    println!("    \x1b[32m{:13}\x1b[0m {}", name, descr);
}

pub fn run(_rl: &mut Shell, _args: &[String]) -> Result<()> {

    println!("\n\x1b[33mCOMMANDS:\x1b[0m");
    help("add",         "Add new entities to the database");
    help("autonoscope", "Manage rules to automatically remove entities from scope");
    help("autoscope",   "Manage rules to automatically add entities to scope");
    help("delete",      "Delete entities from the database");
    help("keyring",     "Manage saved credentials");
    help("pkg",         "Manage installed modules");
    help("noscope",     "Exclude entities from scope");
    help("run",         "Run the currently selected module");
    help("scope",       "Include entities in the scope again");
    help("select",      "Select entities from the database");
    help("target",      "Preview targeted entities or narrow them down");
    help("use",         "Select a module");
    help("workspace",   "Switch to a different workspace");
    help("help",        "Prints this message");
    println!("\nRun <command> -h for more help.\n");

    Ok(())
}