I want to iterate through all files in a directory and open them with an editor, but I don’t want to open the next one until the previous has closed.
something like:
for i in pattern; do vim $i <wait until close> done
Advertisement
Answer
You don’t have to do anything; the shell blocks until vim
exits each time through.