Author Topic: updated gnucash-2.trid.xml for GnuCash data  (Read 675 times)

jenderek

  • Sr. Member
  • ****
  • Posts: 375
updated gnucash-2.trid.xml for GnuCash data
« on: August 06, 2023, 09:25:50 PM »
Hello trid users,

Some days ago i must handle some GnuCash data. These often have file name
suffix GnuCash. So i looked for such files on my systems.

So i run trid utility on my GNUCASH examples. Many are described as "GnuCash
data (V2, ungzipped)" by gnucash-2.trid.xml. But a few (like
MyGnucash8.gnucash MYgnucash-no-gzip.gnucash MYgnucash-xml.gnucash) are only
described as "Generic XML (ASCII)" by xml.trid.xml with mime type text/xml
(See appended output/trid-v-old.txt).

For comparison reason i also run file command (newest version 5.45) on such
samples. Here the samples are also described generic as "XML 1.0 document
text" (See appended file-k-5.45.txt in output) and with mime type
application/x-gnucash (See appended output/file-i-5.45.txt) and no file name
extension (see appended output/file-ext-5.45.txt).

For comparison reason i also run the file format identification utility DROID
(See https://sourceforge.net/projects/droid/). This described the samples also
generic as "Extensible Markup Language" with mime type text/xml by PUID
fmt/101.

On my Linux systems the examples are described as "GnuCash financial data" by
shared MIME-info database by the file name suffix. There the samples instead
of generic mime type text/xml get an own type. That is the type also shown by
file command. That is now expressed by line like:
   <Mime>application/x-gnucash</Mime>

After running tridscan to update gnucash-2.trid.xml inside global strings
section some lines vanished like:
   <String>-- LOCAL VARIABLES</String>
   <String>XML        --</String>
   <String>-- MODE</String>
   <String>-- END</String>

With the updated trid definition now my undetected GnuCash examples are also
described as before with some additional information (see appended
output/trid-v-new.txt). TrID definitions, some samples and output are stored
in archive gnucash-xml.zip. I hope that my definition can be used in future
version of triddefs .

With best wishes
Jörg Jenderek

Mark0

  • Administrator
  • Hero Member
  • *****
  • Posts: 2743
    • Mark0's Home Page
Re: updated gnucash-2.trid.xml for GnuCash data
« Reply #1 on: August 10, 2023, 02:30:51 AM »
Thanks for the update!