私は今日、Expect/TCL で遊んでいます。以下のスクリプトが失敗する理由を誰かに教えてもらいたいと思っていました。
: command not found
./expect3: line 3: send: command not found
#!/usr/bin/expect -f
send " we are going to open up a file for reading, ok? \n"
expect "ok"
set fileopen [open "/home/aaron/text.txt" "r"]
set a [read $fileopen]
send "i am expecting to see a string from the file here $fileopen"
close $fileopen
send コマンドと close コマンドの両方が失敗しますが、spawn コマンドで作成した他のスクリプトは正常に動作するようですか?