I use BibDesk to manage my references, including through auto-filing the corresponding PDF files on disk.
As a result, my .bib files contain several extra fields such as added/modified dates and encoded file paths, as in this example:
@article{xyz17,
Author = {X, Y and Y, Z},
Date-Added = {2017-05-17 16:28:24 +0000},
Date-Modified = {2017-05-17 16:29:46 +0000},
Doi = {10.xxxx/xxx-2017-0001},
Journal = {Foo},
Keywords = {Bar},
Number = {1},
Title = {Hello World},
Year = {2017},
Bdsk-File-1 = {YnBsaXN0MDDUAQIDBAUG ... AAAAAAAAAAAAEIA==}}
Fortunately, BibDesk lets me export my .bib files as "minimal BibTeX" that contains only the essential fields:
@article{xyz17,
Author = {X, Y and Y, Z},
Journal = {Foo},
Number = {1},
Title = {Hello World},
Year = {2017}}
I would like to be able to create such "minimal BibTeX" exports programmatically, through the command line. Thus my question:
Is there a command-line utility to save BibTeX files stripped down to a selection of fields?
sed– Marijn May 21 '17 at 17:08sedper @Marijn's recommendation, and it might well do the trick. – Fr. May 21 '17 at 23:43gawkorsed. – cfr May 22 '17 at 02:00biberstandalone, that may be easier and more robust. – Marijn May 22 '17 at 07:57.bibfiles (even though I effectively do), but for just removing unwanted fields from machine-generated files, effectively, I'd expect it to be relatively straightforward. But Biber would be my preferred tool. – cfr Jun 01 '17 at 03:41