Running a multiline shell command
bobs at twft.com
Fri Dec 9 20:50:27 CST 2011
This has been discussed before, but I am trying to run multiple lines of shell commands using the shell() function. It looked like it worked at first, only the telnet session dumped me before I could get any information out of the switch. Now it looks like I am not even talking to the shell anymore. The shell script looks like this:
print "show mac-address"
I have this in a stack property, and put it into a variable. I replace theUser and thePassword with the actual credentials before running shell(). The result is empty. I have executed the above commands line by line in a terminal and I do end up with a file with the output of the shell window as neat as you please. But when I try to execute within Livecode using the shell() function I get squadouche.
The goal is to get the mac address table from a Procurve managed switch. Any ideas?
More information about the use-livecode