Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document options for bibliographies #73

Open
nickynicolson opened this issue Jan 17, 2023 · 3 comments
Open

Document options for bibliographies #73

nickynicolson opened this issue Jan 17, 2023 · 3 comments

Comments

@nickynicolson
Copy link
Contributor

nickynicolson commented Jan 17, 2023

On a research team site managed with petri-dish, I'd like to include a list of publications output by the team. Ideally we'd store these in a bibliographic data standard format and produce a styled output for viewing as part of the site construction process.

Possible options include:

  • jekyll-scholar (but this not permitted for use in github pages - documented work around)
  • github action to process a bibtex file with pandoc to get a formatted output (as above will require build process change)
  • others?
@peterdesmet
Copy link
Owner

Yeah, that is a good suggestion!

  1. Great that there's already a jekyll-scholar plugin! That should work for people who don't mind running their site locally or using the workaround. I won't not include it in Petridish as I want to keep supporting the simple (default) GitHub Pages setup for users (and thus limit the plugins Petridish uses to those supported by GitHub Pages).
  2. The alternative is indeed a preprocessing of the bibtex or ris file to yml, csv or json. Once it is in the latter formats, Jekyll can read it in a layout (which could be added to Petridish). Not sure what language the preprocessing script should be in. And how to easily offer it as a GitHub Action. Care to experiment with this?

@peterdesmet
Copy link
Owner

peterdesmet commented Jan 20, 2023

Didn't realize the pandoc conversion could be a single line:

pandoc foo.bib -t csljson -o foo.json
# or
pandoc-citeproc --bib2json foo.bib > foo.json

The GitHub actions would then need to be activate on changes to e.g. _data/publications.bib, trigger a conversion and write to _data/publications.json. The latter would be a commit that triggers a site build, where the json file is used in a publications.html layout.

I'm a novice at GitHub actions though, so not sure how to set this up. :-)

@nickynicolson
Copy link
Contributor Author

I've done a bit with actions for merope so I can have a go when I get a moment :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants