#!/usr/bin/expect -f
set dir [lindex $argv 0]
spawn abrt-cli report $dir
set timeout 10
# timeout handler
proc itstime {args} {
puts "!! expect timeout !!"
exit 1
}
while {1} {
expect {
eof {break}
timeout { itstime }
"Ok to upload core dump? (It may contain sensitive data)." {
send "N\n"
}
"This problem was already reported to CentOS Bug Tracker" {
send "y\n"
}
-re "Downloading.*Continue?.*" {
send "N\n"
}
"CentOS Bug Tracker Password" {
send "\n"
}
"CentOS Bug Tracker User name" {
send "\n"
}
"CentOS Bug Tracker CentOS Bug Tracker project" {
send "\n"
}
"Select a workflow to run" {
send "3\n"
}
}
}