So, java properties should be no problem: https://docs.weblate.org/en/latest/formats.html?highlight=java#java-properties
XWiki XML need investigation, but I used itstools to convert xml to standard po in this project https://pagure.io/fedora-cheat-cubes
What I meant is, with weblate handling configuration (ie: were are the files to translate), the commit mechanism (on github it will open a PR), the script should be easier (no more connection to wiki, no more git commands). To be honest, I’m unsure what will still be here at the end.
I use Weblate as an example as it is the only one I really know well. Pootle or Pontoon will have a similar behavios. Some other tool like transifex or Zanata will still require a script to manually push and pull changes.