Skip to content
This repository has been archived by the owner on Apr 5, 2022. It is now read-only.

Latest commit

 

History

History
29 lines (21 loc) · 1.62 KB

README.md

File metadata and controls

29 lines (21 loc) · 1.62 KB

fragmentarium-parser

Build Status Test Coverage Maintainability JavaScript Style Guide

A script to transform fragment database exported from FileMaker to JSON format.

Usage:

node index.js <path to the CSV file>

The CSV must contain a header and have the following columns:

_id,cdliNumber,bmIdNumber,accession,genre,fincke,publication,joins,subcollection,description,length,width,thickness,collection,script,date,folios,record,transliteration,notes,museum
  • joins is parsed to and array with + or \u000b as separator.
  • folios is parsed to an array with as separator.
  • record is parsed to an array of objects with as separator for array entries and as separator for object properties. The resulting objects will have properties user, date, and type.
  • \u000b outside joins is parsed to \n.
  • \u000b in the beginning of string is omitted.

Scripts

  • scripts/expandFolioNumbers.js expands folio numbers in range format (e.g. 08927-8) to individual entries.