0

In TextMate, auto completion of code is achieved by pressing the escape key (on Mac at least). I'm hoping I can also auto complete citations.

I'm writing my text in a markdown document, and using Pandoc to convert the markdown document to a PDF. To build my bibliography, I have a .bib that is linked to the markdown document by Pandoc.

My Pandoc-style in line citations are like this:

[@somebody2013]

I've downloaded and installed the Pandoc bundle from github: https://github.com/dsanson/Pandoc.tmbundle. I was hoping this would enable auto completion of citations, but it has not.

How can I get auto completion of citations to work?

luciano
  • 13,158
  • 36
  • 90
  • 130

1 Answers1

0

From the README for Pandoc.tmbundle:

You must set the following variable in Preferences -> Advanced -> Shell Variables:

$TM_PANDOC_BIB: the path of the bibliography database you want to use.

If you haven't done that, then the citation completion won't work.

David Sanson
  • 136
  • 1
  • 4
  • Unfortunately still not working. Just to clear up what I'm trying to do: 1. type [@som] 2. Press escape key 3. [@som] should expand into [@somebody2013]. This is what I've done 1. Gone to Preferences -> Advanced -> Shell Variables 2. In variable name entered "TM_PANDOC_BIB" 3. In value entered /Users/me/folder/my.bib – luciano May 26 '13 at 14:58
  • The plugin only completes the key, not the brackets (because you might want to add a page reference). Does typing '[@som' followed by escape work? I stopped using TextMate a few years ago, and stopped using the plugin, but last time I used it, this worked. – David Sanson May 27 '13 at 03:00
  • Can you post an issue to the github page? When I get a chance, I'll try to track the problem down. – David Sanson May 28 '13 at 02:41
  • Okay. I just tested it and it worked in TextMate 1.5.11 (1635). It did not work when I tried to set the path to my bibtex file using `$HOME/path/example.bib` or `~/path/example/bib`, but it worked when I specified the full path, `/Users/david/path/example.bib`. – David Sanson May 28 '13 at 19:59