<html>
<head>
<style type="text/css">
<!--
body { line-height: normal; margin-top: 4px; font-variant: normal; margin-left: 4px; margin-right: 4px; margin-bottom: 1px }
p { margin-top: 0; margin-bottom: 0 }
-->
</style>
</head>
<body>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">So, I am trying to run some automation with a bit of end user interaction. If I use the jamf displayMessage binary to display a message it will return the output back into terminal, but I can't seem to quite make the connection.</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">Basically I want to run the command along with other commands and then the user clicks on the OK button it will trigger the last or final command of the policy.</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">Here is what I got, proof of concept wise, but it is very very broken. Anyone else got any ideas?</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">#!/bin/bash</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">#test jamf display message command</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">selection=</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">/usr/sbin/jamf displayMessage -message "testing"</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">until [ "$selection" = "button returned: OK" ] ; do</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">case $selection in</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">"button returned:OK" ) /bin/echo "the test is over" ;;</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande"> esac</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<font size="3" face="Lucida Grande">done</font>
</p>
<br>___________________________<BR>Thomas Larkin<BR>TIS Department<BR>KCKPS USD500<BR><a href="mailto:tlarki@kckps.org">tlarki@kckps.org</a><BR>blackberry: 913-449-7589<BR>office: 913-627-0351<BR>chown -R us /.base<BR><BR><BR><BR><br><br></body>
</html>