GNOME Bugzilla – Bug 781813
Can't push simple-scan branches due pre-receive hook
Last modified: 2017-04-27 09:03:57 UTC
I imported simple-scan into git from bzr. However I didn't import the branches. If I try and push them now I get:
Counting objects: 8, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (8/8), done.
Writing objects: 100% (8/8), 865 bytes | 0 bytes/s, done.
Total 8 (delta 6), reused 0 (delta 0)
remote: The following translation (.po) file appears to be invalid. (When updating branch 'gnome-3-24'.)
remote: The results of the validation follow. Please correct the errors on the line numbers mentioned and try to push again.
remote: <stdin>:1:2: syntax error
remote: <stdin>:1: keyword "ar" unknown
remote: msgfmt: (null): warning: PO file header missing or invalid
remote: warning: charset conversion will not work
remote: msgfmt: found 3 fatal errors
remote: To check this locally before attempting to push again, you can use the following command:
remote: msgfmt -c ar.po
remote: After making fixes, modify your commit to include them, by doing:
remote: git add ar.po
remote: git commit --amend
remote: If you have any further problems or questions, please contact the GNOME Translation Project mailing list <email@example.com>. Thank you.
! [remote rejected] gnome-3-24 -> gnome-3-24 (pre-receive hook declined)
error: failed to push some refs to 'ssh://firstname.lastname@example.org/git/simple-scan'
I think I need to get back to import mode to push these?
It's the first time I see this... why do you have individual PO files in the /help folder, and /help/<lang> folders contain a link to he previous PO file?
Help translations should be in the format of /help/<lang>/lang.po. It seems the pre-commit hook is not able to follow links, so it complain with the format of the softlink link, since it isn't a valid PO file structure.
Yo should move each PO file to its own language folder, and then try to commit again.
Hope this helps
I had to put them there so Launchpad would do the translation integration. I will fix the commits now but I was wondering if there was a way to import the git tree as-is before fixing issues like this.
OK, I worked it out, thanks!