handling ctrl-c in a bash script

Developer from somewhere

#!/bin/bash

trap ctrl_c INT

function ctrl_c() {
  # do whatever cleanup you want here
}