canic-host 0.99.18

Host-side App build, Fleet install, deployment, and release-set library for Canic workspaces
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use crate::release_set::AppConfigSnapshot;
use std::{path::Path, process::Command};

pub(super) fn add_local_root_create_cycles_arg(
    command: &mut Command,
    config_path: &Path,
    environment: &str,
) -> Result<(), Box<dyn std::error::Error>> {
    if environment != "local" {
        return Ok(());
    }

    let cycles = AppConfigSnapshot::load(config_path)?.local_root_create_cycles();
    command.args(["--cycles", &cycles.to_string()]);
    Ok(())
}