fixed sed script to correct index of the root folder