I need to extract the filename and containing directory from a full path (DOS syntax). I need to do this using sed as it is part of a larger regular expression.
Example input: ..\home\test\somedir\anotherdir\myfile.txt
Expected output: anotherdir\myfile.txt
Any help would be greatly appreciated.
Thanks