Created
July 13, 2020 18:50
-
-
Save tfcollins/30d062e9f631d58a6761f792bc0eb38c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
screen -S Installer -dm bash -c "$1/$2/bin/matlab $3 -r 'genLTEPAInstaller'" | |
echo "MATLAB launched" | |
for ii in {1..500} | |
do | |
echo $ii | |
echo "Active MATLAB session IDs: $(pidof MATLAB)" | |
screen -list | grep Installer | |
if [ -f LTEPA/for_redistribution/LTEPAInstaller.install ]; then | |
echo "Generated installer found" | |
echo "Stopping MATLAB" | |
sleep 4 | |
screen -X -S Installer quit | |
screen -list | |
exit 0 | |
fi | |
sleep 1 | |
done | |
exit 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment