#!/usr/bin/expect -f #USAGE: [script name] ["station name"] [# of seconds to record (accepts float)] set force_conservative 0 set timeout -1 match_max 100000 spawn $env(SHELL) set station [lindex $argv 0] set record_length [lindex $argv 1] send -- "pyxis -r \"$station\"\r" sleep $record_length send -- "" exit