question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could xlf output be better formatted

See original GitHub issue

I’m using xliffmerge right now and I was wondering if the output could be more human readable. For example now it generates output like this:

<target state="new">Name:</target></trans-unit><trans-unit id="380b43f6f630204545ad0e23c206e97c5c4bdecb" datatype="html">
  <source>Reward:</source>
        
<target state="new">Reward:</target><context-group purpose="location"><context context-type="sourcefile">example.component.ts</context><context context-type="linenumber">37</context></context-group></trans-unit><trans-unit id="ea71da1aed0ad121e79a8e73c0d66ec10c52e36d" datatype="html">  <source>Number of uses:</source>
        
<target state="new">Number of uses:</target><context-group purpose="location"><context context-type="sourcefile">example.component.ts</context><context context-type="linenumber">50</context></context-group></trans-unit><trans-unit id="3c02902d1e6bc749c646f88b6f7d3e019440df63" datatype="html">

While I would appreciate it to be more like this:

  <target state="new">Name:</target>
</trans-unit>

<trans-unit id="380b43f6f630204545ad0e23c206e97c5c4bdecb" datatype="html">
  <source>Reward:</source><target state="new">Reward:</target>
  <context-group purpose="location">
    <context context-type="sourcefile">example.component.ts</context>
    <context context-type="linenumber">37</context>
  </context-group>
</trans-unit>

<trans-unit id="ea71da1aed0ad121e79a8e73c0d66ec10c52e36d" datatype="html">  
  <source>Number of uses:</source><target state="new">Number of uses:</target>
  <context-group purpose="location">
    <context context-type="sourcefile">example.component.ts</context>
    <context context-type="linenumber">50</context>
  </context-group>
</trans-unit>

<trans-unit id="3c02902d1e6bc749c646f88b6f7d3e019440df63" datatype="html">

The output is correct of course but it’s a little tedious to translate this right in the xlf file.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
martinroobcommented, Apr 25, 2018

This should be possible. I will have a look at it

2reactions
eweapcommented, Apr 24, 2018

@martinroob @martinsik Can’t we add a pretty-xml call on the output before writing in the final xlf file ? (@martinroob thanks for your work btw !)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tools for xlf/xmb files - Stack Overflow
So can somebody tell me what are the tools that help to open/deal with xlf(translation) files of angular-i18n? internationalization · angular5 ...
Read more >
Avoiding or fixing upgrade problems - IBM
Table 1. Potential problems migrating programs to XL Fortran V15.1.3. The column on the right shows which problems you can avoid by using...
Read more >
Inline formatting tag issue and segmentation problems in XLF ...
Hello. We are stuck. Having been able to work out some embedding coding for some of our other XLF files a new issue...
Read more >
Working with Translation Files
XLIFF is the XML Localization Interchange File Format. It is the standard format used by localization providers. For more information about the XLIFF ......
Read more >
List-Directed Formatting
A comma or slash can be preceded and followed by one or more blanks. List-Directed Input. Input list items in a list-directed READ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found