Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
# Setup
This document notes how SVLMD is setup. 

## Citation
SVLMD uses [Zotero](https://www.zotero.org/), [Better Bibtex](https://retorque.re/zotero-better-bibtex/), and [Logseq Citation Manager](https://github.com/sawhney17/logseq-citation-manager/) to handle citations.

1. Add postscript to Better Bibtex by going to Zotero > Edit > Settings > Better Bibtex
```
if (Translator.BetterBibLaTeX) {
    // Simple year extraction
    if (zotero.date) {
        const match = zotero.date.match(/\b\d{4}\b/)
        if (match) {
            tex.add({ name: 'year', value: match[0] })
        }
    }

    // Use editor as author if no author field exists
    // Hack for Logseq citation manager
    if (!tex.has.author) {
        for (const creator of zotero.creators) {
            if (creator.creatorType === 'editor') creator.creatorType = 'author'
        }
      tex.addCreators();
    }
}
```
This script extracts the year from date field, which will be needed due to how we setup SVLMD to work with Logseq Citation Manager.

2. Export `references.bib` to [../assets/storages/logseq-citation-manager/references.bib] as Better BibLaTex via Zotero, and set to keep it updated.

3. Make sure to import the Logseq Citation Manager settings.