59 lines
2.2 KiB
Bash
Executable File
59 lines
2.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
repo_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
expected_omnisocket_commit="de3f5c96779dbe1571c10feb22fc7f2331b6b222"
|
|
|
|
for executable in \
|
|
"$repo_dir/tg3_omnisocket_transport/omnisocket_xtele_sender.py" \
|
|
"$repo_dir/tg3_local_teleop/tg3_local_teleop.py" \
|
|
"$repo_dir/tg3_local_teleop/data_recorder_node.py" \
|
|
"$repo_dir/tg3_local_teleop/run.sh" \
|
|
"$repo_dir/tg3_local_teleop/run_data_recorder.sh" \
|
|
"$repo_dir/tg3_local_teleop/wait_ros_ready.sh" \
|
|
"$repo_dir/tg3_local_teleop/home.sh" \
|
|
"$repo_dir/tg3_local_teleop/status.sh" \
|
|
"$repo_dir/tg3_data_collection/data_get_sync.py"; do
|
|
if [[ ! -x "$executable" ]]; then
|
|
echo "Required executable bit is missing: $executable" >&2
|
|
exit 1
|
|
fi
|
|
done
|
|
|
|
python3 -m py_compile \
|
|
"$repo_dir/tg3_omnisocket_transport/omnisocket_xtele_sender.py" \
|
|
"$repo_dir/tg3_local_teleop/tg3_local_teleop.py" \
|
|
"$repo_dir/tg3_local_teleop/gesture_toggle.py" \
|
|
"$repo_dir/tg3_local_teleop/data_collection.py" \
|
|
"$repo_dir/tg3_local_teleop/data_recorder_protocol.py" \
|
|
"$repo_dir/tg3_local_teleop/data_recorder_node.py" \
|
|
"$repo_dir/tg3_data_collection/data_get_sync.py"
|
|
python3 "$repo_dir/tg3_omnisocket_transport/test_session_gate.py"
|
|
python3 "$repo_dir/tg3_local_teleop/test_session_gate.py"
|
|
python3 "$repo_dir/tg3_local_teleop/test_gesture_toggle.py"
|
|
python3 "$repo_dir/tg3_local_teleop/test_idle_session_refresh.py"
|
|
python3 "$repo_dir/tg3_local_teleop/test_data_collection.py"
|
|
python3 "$repo_dir/tg3_local_teleop/test_data_recorder_protocol.py"
|
|
python3 "$repo_dir/tg3_data_collection/test_data_get_sync.py"
|
|
python3 - "$repo_dir/tg3_local_teleop/config.toml" <<'PY'
|
|
import sys
|
|
import tomllib
|
|
|
|
with open(sys.argv[1], "rb") as stream:
|
|
tomllib.load(stream)
|
|
print("config.toml parse passed")
|
|
PY
|
|
|
|
if [[ -n "${OMNISOCKETGO_DIR:-}" ]]; then
|
|
actual_omnisocket_commit="$(git -C "$OMNISOCKETGO_DIR" rev-parse HEAD)"
|
|
if [[ "$actual_omnisocket_commit" != "$expected_omnisocket_commit" ]]; then
|
|
echo "OmniSocketGo commit mismatch: $actual_omnisocket_commit" >&2
|
|
exit 1
|
|
fi
|
|
echo "OmniSocketGo commit verified: $actual_omnisocket_commit"
|
|
else
|
|
echo "OmniSocketGo is external and was not checked; expected commit: $expected_omnisocket_commit"
|
|
fi
|
|
|
|
echo "All offline TG3 checks passed"
|