A python version using bibtexparser bibtexparser and pandas
with open('ref.bib') as bibtex_file:
bib_database = bibtexparser.load(bibtex_file)
df = pd.DataFrame(bib_database.entries)
df.to_csv('ref.csv', index=False)
And a minimal working example:
import bibtexparser
import pandas as pd
bibtex = """@article{ einstein1935can,
title={Can quantum-mechanical description of physical reality be considered complete?},
author={Einstein, Albert and Podolsky, Boris and Rosen, Nathan},
journal={Physical review},
volume={47},number={10},
pages={777},
year={1935},
publisher={APS}}
@inproceedings{sharma2017daniel,
title={DANIEL: A deep architecture for automatic analysis and retrieval of building floor plans},
author={Sharma, Divya and Gupta, Nitin and Chattopadhyay, Chiranjoy and Mehta, Sameep},
booktitle={2017 14th IAPR International Conference on Document Analysis and Recognition (ICDAR)},
volume={1},pages={420--425},year={2017},organization={IEEE}}"""
with open('ref.bib', 'w') as bibfile:
bibfile.write(bibtex)
with open('ref.bib') as bibtex_file:
bib_database = bibtexparser.load(bibtex_file)
df = pd.DataFrame(bib_database.entries)
df.to_csv('ref.csv', index=False)