nixpulvis / oursh

Your comrade through the perilous world of UNIX.
http://nixpulvis.com/oursh/oursh
MIT License
67 stars 6 forks source link

Variables #51

Closed nixpulvis closed 3 years ago

nixpulvis commented 3 years ago

Implements the following variable related functions:

assert_oursh!("X=1; echo $X", "1\n");
assert_oursh!("export FOO=1 BAR=$FOO; echo $BAR", "1\n");
assert_oursh!("echo $BAR", "\n");
assert_oursh!("echo $", "$\n");
assert_oursh!("echo ' $ '", " $ \n");
assert_oursh!("echo \" $$ $ \"", " $$ $ \n");