Dave-ee Jones Posted May 3, 2017 Share Posted May 3, 2017 Hi guys, I'm trying to source a .sh script like so: source /root/udisk/payloads/$SWITCH_POSITION/hi.sh And it seems to run the script, but then suddenly seems to push it to the background, as if I used '&' at the end...Or it just stops the script part way through.At least, that's what I thought until I saw it doing the end of the script... So if I put something like this in the hi.sh file: LED R sleep 1 LED M sleep 1 LED B sleep 1 LED C sleep 1 LED G sleep 1 LED Y sleep 1 LED W and then call it like so: source /root/udisk/payloads/$SWITCH_POSITION/hi.sh LED R 100 It will only show the white LED (the very last one in the script) and then start flashing red. It seems to be skipping the sleep functions, zooming through the script...Any ideas on why this is? Could just be me not calling the sleep function correctly... Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.