File: run

package info (click to toggle)
tkey-ssh-agent 1.0.0%2Bds-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 444 kB
  • sloc: sh: 178; makefile: 100; python: 95
file content (32 lines) | stat: -rwxr-xr-x 679 bytes parent folder | download
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
#!/bin/sh
set -eu

cd "${0%/*}/.."

if [ -e tkey-sign ]; then
  if ! go version -m tkey-sign | grep -q main.signerAppNoTouch=indeed; then
    printf "We need to build with the touch requirement removed.\n"
    printf "Please first do: make -C ../ clean\n"
    exit 1
  fi
fi

if [ ! -e tkey-runapp ] || [ ! -e apps/signer/app.bin ] || [ ! -e tkey-sign ]; then
  make TKEY_SIGNER_APP_NO_TOUCH=indeed -C apps
  make TKEY_SIGNER_APP_NO_TOUCH=indeed tkey-runapp tkey-sign
fi

cd "test"

if [ ! -e venv ]; then
  if ! python3 -m venv venv; then
    rm -rf venv
    exit 1
  fi
  . ./venv/bin/activate
  pip3 install -r requirements.txt
else
  . ./venv/bin/activate
fi

./test-loop.py