Bug fix: dont append remote files, overwrite it.