From 745728caf8b2f5eb11b31030ef709a8ad093d27b Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Mon, 9 Sep 2019 20:19:59 +0300 Subject: Travis: write to database from track_status.py --- .travis/track_status.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.travis/track_status.sh b/.travis/track_status.sh index 0e3d2d8..5a473f0 100755 --- a/.travis/track_status.sh +++ b/.travis/track_status.sh @@ -7,13 +7,17 @@ track_status() { log_path="$( mktemp )" echo "Log file path: $log_path" - local rm_log_path - rm_log_path="$( printf -- 'rm -f -- %q' "$log_path" )" + local db_path + db_path="$( mktemp --dry-run )" + echo "DB file path: $db_path" - trap "$rm_log_path" RETURN + local rm_aux_files + rm_aux_files="$( printf -- 'rm -f -- %q' "$log_path" "$db_path" )" + + trap "$rm_aux_files" RETURN echo 'Running track_status.py...' - python3 -m bin.track_status egor.tensin --log "$log_path" & + python3 -m bin.track_status egor.tensin --log "$log_path" --format csv --output "$db_path" & local pid="$!" echo "Its PID is $pid" -- cgit v1.2.3