-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtinycc.sh
More file actions
executable file
·43 lines (39 loc) · 1.61 KB
/
tinycc.sh
File metadata and controls
executable file
·43 lines (39 loc) · 1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
#//////////////////////////////////////////////////////////////
#// ____ //
#// | __ ) ___ _ __ ___ _ _ _ __ ___ _ __ _ __ ___ //
#// | _ \ / _ \ '_ \/ __| | | | '_ \ / _ \ '__| '_ \ / __| //
#// | |_) | __/ | | \__ \ |_| | |_) | __/ | | |_) | (__ //
#// |____/ \___|_| |_|___/\__,_| .__/ \___|_| | .__/ \___| //
#// |_| |_| //
#//////////////////////////////////////////////////////////////
#// //
#// Script, 2021 //
#// Created: 27, May, 2021 //
#// Modified: 27, May, 2021 //
#// file: - //
#// - //
#// Source: - //
#// OS: ALL //
#// CPU: ALL //
#// //
#//////////////////////////////////////////////////////////////
TAG_VERSION=latest
DOCKER_IMAGE=bensuperpc/tinycc
case "$1" in
-version|-v)
TAG_VERSION=$2
shift
shift
;;&
-h)
echo "Usage: ${0##*/} [-version latest tcc -o hello hello.c]"
exit 1
;;
esac
if [ $# -eq 0 ]
then
echo "No arguments supplied"
exit 1
fi
docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp ${DOCKER_IMAGE}:${TAG_VERSION} $@