I have a very simple script, let's call it foo.sh. It's this:
#!/bin/sh sxhkd & panel &
panel is a script (I won't post it here because it's very long and I don't think it would be relevant) which will spawn some child processes.
I execute the script with
Now, my problem is that if I kill panel from another shell with
pkill panel for some reason sxhkd is also killed, and that is very undesiderable. I tried ampersand, disown, nohup, and I haven't got other ideas.
How can I avoid that?