on *:text:!dostats:#: {
run batchfilename.bat
msg $chan Stats updated, check http://www....com/
}
Of course, you'll probably want to limit this to only voiced or opped users or use the userlist levels to limit it to specific user levels. Also, I'm assuming pisg takes awhile to create the file and get it uploaded, so you might want to put a timer on the msg line to send the msg 30-60 seconds (or whatever it takes to get it created/uploaded) after the /run command.