I'm currently trying to retrieve a single file from a GitLab Repo with the following command (I'm on Windows):
git archive --remote=git@git.myrepo.de:path/to/repo.git HEAD dir1/dir2/MyFile.xml > MyFile.xml
Essentially it works, but there are some strange artifacts in front and after the actual content of the file. This is how the command prompt shows them:
The XML version tag at the bottom of the image is the start of the actual file content. Does anyone have an idea how to get rid of this?