a newline at the end of 8script makes it succeed in Linux. Otherwise, it doesn't read the last command correctly