I have a script where I start it in the script but it needs "end" to be typed to shut down correctly, Is there anyway I can this from inside the script with the PID?
For this case you can even use a here-string:
$ myscript <<< end
This will make your script read from the given string instead of stdin
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With