Created
May 22, 2020 06:28
-
-
Save tarleb/afee1b1d97e52aca888f410e77b3624a to your computer and use it in GitHub Desktop.
Filter to highlight some authors in the bibliography
Thank you very much for very detailed instructions. I should have probably mentioned that I am a markdown novice. And this is first time touching a lua file. I tried adding test.lua to my folder and to _output.yml here, but it didn't produce any result either (probably I should change something more).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The highlight-author.lua filter only works with old versions of pandoc that use pandoc-citeproc. The other filter should work, but you have to be careful about how your name and initials are output by the csl you are using. Try converting to a .json file first to see how your csl treats initials, commas, periods, etc and make sure that you copy the strings correctly into the filter. I did a quick search in Scopus for Ayhan and created a short bibliography to test (as .json file, can also be .bib) - not sure if this is you, but you can adjust accordingly. I include below a text with two references (save as test.txt), the lua filter modified with your name (save as test.lua), the bibliography (save as biblio.json) and a csl file that I use to create a cv with my name underlined (so it puts all the details in the citation, not in a bibliography at the end - save as CiteOnly.csl). The command:
should give you the correct result with name underlined - or use -o test.html if you don't want pdf. Then try with your csl file, if it doesn't work, convert to .json (pandoc -t json etc.), check how your initials are formated and adjust the lua filter.
Files:
test.txt
test.lua
biblio.json
CiteOnly.csl