use the built in fnamemodify() to make a path relative

Closes #383