create-proyect-cli 2.2.0

CLI para crear proyectos rĂ¡pidamente (Express, Rust, Python, Angular, Vue, React)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use std::process::Command;

pub fn generate_vue(name: &str) {
    let npx = if cfg!(target_os = "windows") {
        "npx.cmd"
    } else {
        "npx"
    };

    println!("Creando proyecto Vue...");

    Command::new(npx)
        .args(["create-vite", name, "--template", "vue"])
        .status()
        .expect("Error creando proyecto Vue");
}