Improving a workflow for importing BibTeX citations

Source: http://tex.stackexchange.com/questions/79251/improving-a-workflow-for-importing-bibtex-citations

You can set up Jabref to automatically import a reference from Firefox into the current database, but it’s somewhat arcane. Here is my solution under Linux:

  • 1) Select Options -> Preferences -> Advanced — and check „Listen for remote operation …“ I don’t think it matters which port.
  • 2) Create a small bash script (text file) named „jabref-import“ that looks like this:

Replace „~/local/jabref/JabRef-2.8.1.jar“ with the path to your Jabref .jar file on your machine. Or if you have a working executable called „jabref“, you can replace everything before the „-i“ with „jabref“. Just make sure your executable accepts command-line options (mine didn’t).

In Ubuntu 13.04, the following variant of the script works:

where which jabref searches for an executable called jabref on your current $PATH.

3) Make the file executable:

4) Make sure Jabref is already open. Go to Firefox, download a citation file. It could be a .bib or .ris or .ref or whatever. Select the „Open with…“ option in the dialog, and select the jabref-import executable that you just made. The import dialog should pop up in Jabref with your citation.