My favourite trick for this problem in general is to add a pause()
system call to the front of my code. That stops the process until it receives a signal, and the act of attaching the debugger generates that signal and thus you can just continue from there.
Note that I’ve never tried it with SwiftPM plug-in, but I’ve used it in a wide variety of other circumstances.
Share and Enjoy
Quinn “The Eskimo!” @ DTS @ Apple