^C
sends a SIGINT
to all the processes in the foreground process group. To do the equivalent with kill
, you should send the signal to the process group (OS-level concept):
kill -SIGINT -<pid>
or to the job (shell-level concept, the pipeline ended with &
):
kill -SIGINT %