summaryrefslogtreecommitdiff
path: root/templates/_registry.rs.template
blob: cac3c8efe1b6089e18dc052352be6a90e32d56e0 (plain)
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
32
33
// Auto generated by build.rs
use crate::cmd::cmd_system::{JVCommand, JVCommandContext};
use crate::cmd::errors::CmdProcessError;
<<LINE>>
/// Input parameters, execute a command node
pub async fn jv_cmd_process_node(
    node: &str,
    args: Vec<String>,
    ctx: JVCommandContext,
    renderer_override: String
) -> Result<crate::cmd::renderer::JVRenderResult, crate::cmd::errors::CmdProcessError> {
    match node {
// PROCESS
// -- TEMPLATE START --
        // Command `<<KEY>>`
        "<<NODE_NAME>>" => {
            return crate::<<COMMAND_TYPE>>::process_with_renderer_flag(
                args,
                ctx,
                renderer_override
            )
            .await;
        }
// -- TEMPLATE END --
        _ => {}
    }
    return Err(CmdProcessError::NoNodeFound(node.to_string()));
}
<<LINE>>
/// Get all command nodes
pub fn jv_cmd_nodes() -> Vec<String> {
    vec!<<NODES>>
}