Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Keep po files line length at 80 characters #3
Its quite annoying that all translation editors do that, wrap translations strings at 80 characters, but then when you update the po files with i18ndude they are unwrapped and kept as huge lines.
More over, it makes it difficult to grasp the changes if you have translations in a version control system, as lots of strings show up in the diff.
See below how it should look like:
Short lines (the second one) should be kept within a single line. For longer lines, the line with the msgstr is kept empty and all the text goes below (string 1).
The same goes for the msgid (as seen also on string 1).
For location lines (the ones starting with
Okay, I have fixed this.
When writing files the script wraps msgid and msgstr lines at 79 characters, as most PO editors do that. You can set an environment variable
A command line option would have been nicer, but the way the script current reads command line arguments makes that hard, needing a lot of changes. Rewriting the script to use
I have changed this. i18ndude does not look for a
I have released 3.3.0 with this change.