NatLibFi / RecordManager

A metadata record management system written in PHP, intended to be used in conjunction with VuFind or another Solr-based discovery interface. Provides import, export, harvesting (OAI-PMH), normalization, deduplication and Solr index update functionality with support for multiple metadata formats. Also includes an OAI-PMH provider that can be used to access the data stored in RecordManager database. Functionality driven by simple command line programs for easy automation.
GNU General Public License v2.0
47 stars 31 forks source link

Export: Add timestamp injection, path and namespace support. #151

Closed EreMaijala closed 9 months ago

EreMaijala commented 9 months ago

@demiankatz Could you check if these work for you? Docs missing, but you can do e.g.

./console re:ex --source=foo --inject-created='created' --inject-date="updated" foo.xml

or

./console re:ex --source=foo --inject-created='custom:date/created[@foo="bar"]' --inject-date="custom:date/updated" --add-namespace="custom=http://foobar" foo.xml

EreMaijala commented 9 months ago

@demiankatz Tweaked and simplified. Does it still work for you? I changed the namespace handling a bit so that if you add an element like customNS:foo/bar, bar will inherit customNS.

demiankatz commented 9 months ago

@EreMaijala, I just exported again and got the same results, so I think all is well. I'll review the code changes later when I have a bit more time!