I have to swap two consecutive line using sed in a file.
My text to swap is available in the file x.pl
#Create & map a common work library
if (!(-e "../work"))
{
system ("vlib work ../work");
system ("vmap work ../work");
}
system ("vsimsa -do thiagu_dec.do");
In this i want to swap the line
system ("vmap work ../work");
}
ie after swapping it should update in the file as
}
system ("vmap work ../work");
I need this updation in many files in a directory.