run.sh 296 B

12345678910111213141516171819
  1. #!/bin/bash
  2. TARGETS=("demo1" "demo2")
  3. demo2() {
  4. PYTHONPATH=./src ./build/demo2
  5. }
  6. demo1() {
  7. python3 src/demo1_get-price.py
  8. }
  9. # determine target from argument
  10. if [[ " ${TARGETS[@]} " =~ " $1 " ]]; then
  11. "$1"
  12. else
  13. echo "Available targets: ${TARGETS[*]}"
  14. echo "Usage: $0 [target]"
  15. fi