pranaless

joined 1 year ago
[–] [email protected] 3 points 9 months ago

Hi hi, MangoKangaroo! Wow, being called by a name that I chose myself feels really nice.

[–] [email protected] 5 points 9 months ago (2 children)

I cracked. Hi! I'm Prana, a trans girl.

[–] [email protected] 3 points 10 months ago* (last edited 10 months ago)
[–] [email protected] 1 points 10 months ago

Yes and no. While coreutils does provide an echo binary, shells also have a built-in for optimisation purposes.

At first I had the code calling the binary directly, but then changed it to spawning a shell (and so using the builtin). It's very cursed either way.

[–] [email protected] 31 points 10 months ago (5 children)
use std::process::Command;

fn main() {
    Command::new("sh")
        .arg("-c")
        .arg("echo Hello World!")
        .spawn()
        .unwrap();
}

Like this?