Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Edit a Language File Module - Blank Strings
12-04-2017, 09:30 PM,
RE: Edit a Language File Module - Blank Strings
(12-04-2017, 09:06 AM)falkoner Wrote: Phil is right that the no-wrap parameter is needed on msmerge as well as xgettext, but if I remember correctly if the file you are merging into already has the line breaks then they will persist after the merge regardless of this setting. Though my knowledge is a few years old so it may have changed, but it sounds from what Paul is saying that this is still the case.

I do remember writing a bash script to remove these, but I have had a quick look around and can't immediately see this so it may have got lost on one of my laptop thefts or hard disk crashes Sad


The attached is a quickly hacked command line PHP script that _should_ remove the line wraps from a messages.po file. You may need to change the path to the command line php executable on line 1 (I am using PHP7) and the two directories on line 4 and 5 will need changing to yours. It is then run with a command similar to this:

./FixPO.php en US

Note please test and check before replacing the actual messages.po file


Attached Files
.php   FixPO.php (Size: 2.12 KB / Downloads: 2)

Messages In This Thread
RE: Edit a Language File Module - Blank Strings - by falkoner - 12-04-2017, 09:30 PM

Forum Jump:

Users browsing this thread: 1 Guest(s)