compiler-discord/docker/cpp/run.sh

7 lines
140 B
Bash
Raw Normal View History

mkdir "$CODEDIR" && cd "$CODEDIR"
printf %s "$1" > program.cpp
g++ program.cpp -o program && ./program || true
cd .. && rm -rf "$CODEDIR"