Skip to content

Instantly share code, notes, and snippets.

View jmrepetti's full-sized avatar

jmrepetti jmrepetti

View GitHub Profile
@jmrepetti
jmrepetti / cargo.sh
Last active April 1, 2023 17:27
Generate Rust project using Podman
#!/bin/bash
podman run \
-i `#Keep STDIN open even if not attached`\
-t `#Allocate a pseudo-TTY for container`\
--rm `#Remove container (and pod if created) after exit`\
-e CARGO_HOME=./cargo `#persist registry within project`\
-v ./:/new_rust_project `#Bind mount a volume into the container`\
--security-opt label=disable `#allow me to write on mounted volume`\
-w /new_rust_project `#Working directory inside the container`\
--name rust_cmd `#Assign a name to the container`\