BibTeX-to-HTML Citation Generator
bibtex references generator (IEEE format)
Upload a bibtex file
Introduction
BibTeX is awesome. It’s an effortless way to keep track of citations which most any publisher offers for papers. It contains the metadata for citations which can then be used when writing LaTeX documents. Sometimes, though, I just want a quick and easy way to generate citation(s) for a given bibtex file (ie quick reference in a powerpoint slide) without creating a “dummy” latex file just to get one citation. That’s why I created this automatic citation maker. Upload your bibtex file and it will generate a list of citations in HTML/text form.
Code Overview
The file upload uploads the bib file to an AWS S3 bucket and triggers an AWS Lambda instance to begin processing. The Lambda instance converts the bib file to an HTML bibliography using pandoc
with the help of a template tex file, and re-uploads the HTML file to S3 so that your browser can fetch it.
Some notes:
- When clicking upload, actually a Lambda instance presigns an S3 bucket link which gets sent back to the browser and then the browser can upload it to S3
- CORS - both the client’s request (“preflight”) and the server’s response (“request”) matter and must be configured.
- The converting Lambda function needs a “Layer” containing the pandoc binaries. The pre-existing Serverless App Repository’s Lambda Layer was great except they didn’t include the
pandoc-citeproc
binary, so I recompiled using their scripts and made a new layer. - Someday maybe I’ll add support for additional styles other than just IEEE. Pandoc/Lambda can already do it easily, it’s just a matter of making a dropdown or something to select which style you want. I’m too lazy and also don’t see myself needing other formats for the foreseeable future.
Code
The code is very disorganized and lacking documentation. Contact me if you have any questions.