I got a bunch of xml files in a GitLab repo but unfortunately they are not formatted. Is is basically one line with all the tags inside it. So the files are very difficult to read.
Is there an option in GitLab to format the xml files and make them more readable?
Something like this but build into GitLab:
http://www.freeformatter.com/xml-formatter.html
GitLab does not support this and I don't think GitLab is the right environment to reformat or beautify code. It is continuous integration server, not a development environment. Just fetch the code, format it in your IDE (e.g. Visual Studio or NetBeans) and then commit and push it again. GitLabs code editor is only meant for correcting small parts of code.
When GitLab would implement reformatting XML, it should also support other common file formats, like Java and HTML. This would require a lot of effort, while any mature IDE supports it out of the box. It would also require a lot of format settings in GitLab, like tab width and the position of brackets, which would then need to match the format settings in your IDE in order to avoid formatting conflicts.