forked from deepcausality-rs/deep_causality
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.sh
executable file
·57 lines (48 loc) · 1.27 KB
/
example.sh
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# SPDX-License-Identifier: MIT
# Copyright (c) "2023" . The DeepCausality Authors. All Rights Reserved.
set -o errexit
set -o nounset
set -o pipefail
# Bash Select (Make Menu) https://linuxize.com/post/bash-select/
echo ""
echo "--------------------------------"
echo "Select example to run: "
echo "--------------------------------"
echo "csm: Causal state machine"
echo "ctx: Causal model with base (static) context"
echo "starter: Simplest getting started example"
echo "smoking: Simple causal model without Context"
echo "--------------------------------"
echo ""
select opt in csm ctx starter smoking quit;
do
case $opt in
csm)
echo "Selected example: CSM (Causal State Machine)"
command cargo run --release --bin example-csm
break
;;
ctx)
echo "Selected example: CTX (Context)"
command cargo run --release --bin example-ctx
break
;;
starter)
echo "Selected example: Starter (Starter)"
command cargo run --release --bin example-starter
break
;;
smoking)
echo "Selected example: SMOKING (Smoking)"
command cargo run --release --bin example-smoking
break
;;
quit)
echo "Exiting!"
exit 0
;;
*)
echo "Invalid option $REPLY"
;;
esac
done