#!/bin/sh cd /tmp cat <<'EOF' > /tmp/$$.rs fn main() { println!("hello, script") } EOF rustc $$.rs && ./$$