Fix rebase with files ending with /