Is there a synchronized exec in ruby? I try the following code and when I open the file I get nothing, and it's probably because exec doesn't finish writing the file.
exec "sort data.txt > data.sort"
File.foreach("data.sort") { |line| puts line}
Ted