Skip to content

Commit 64b7584

Browse files
committed
diff
1 parent bed9a7f commit 64b7584

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

fantasyloop.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
SOURCE_DIR=".javascript-fantasy-names-deprecated/generators"
33
source .venv/bin/activate
44
: ${counto:=0}
5+
: ${diff:=0}
56
: ${VERBOSITY:=0}
67
reads=''
78
mass_reader () {
@@ -21,7 +22,8 @@ add_score() {
2122
# Function to be called when Ctrl+C is pressed
2223
ctrl_c() {
2324
echo -e "\n** Ouch! SIGINT received (Ctrl+C). Performing cleanup..." >&2
24-
# Add your cleanup logic here (e.g., remove temporary files, stop services)
25+
time2=$(date +%s.%N)
26+
export diff=$(echo "scale=40;${time2} - ${time1}" | bc)
2527
add_score "interrupt-fail"
2628
#echo "${this_new_name},${model_name},${diff},${loopster_count},interrupt-fail" >> score.csv
2729
echo "** Cleanup complete. Exiting script." >&2
@@ -74,7 +76,7 @@ do_aider () {
7476
time ${AIDER_CMD} -m "${MESSAGE}"
7577

7678
time2=$(date +%s.%N)
77-
diff=$(echo "scale=40;${time2} - ${time1}" | bc)
79+
export diff=$(echo "scale=40;${time2} - ${time1}" | bc)
7880
clean_dirty_git
7981
set +e
8082
bats test/full.bats

0 commit comments

Comments
 (0)