Is there a way to throw a control-c break to a task running as @spawn? The specific case is that, when running the SoX commandline music player, one sends control-c to tell the player to stop play, ie
@spawn or not, if you are talking about sending a Control-C to the subprocess you are actually talking about sending a SIGINT to the subprocess. Sending a interupt (however you interpret that) to the task you forked off won’t do anything.
In another word, all what you need is kill(process, Base.SIGINT) you just need to figure out a way to get tha process object and you can pick you way to do it whether you want to use @spawn or not.