JabRef
v4
v4
  • JabRef Bibliography Management
  • General information about JabRef
    • Entry Editor
    • Best Practices
    • Command line use and options
    • Automatic Backup (.sav and .bak) and Autosave
    • Remote operation
    • Installation
  • About BibTeX and its fields
    • URL and DOI links in JabRef
    • File links in JabRef
    • Links to other entries
    • The 'owner' field
    • Time stamped fileds
    • Journal abbreviations
    • Special Fields
    • Set/clear/rename fields
    • Field content selector
    • Strings
  • Finding, Sorting, and Cleaning Entries
    • Searching within the library
    • Searching externally using Online Services
      • ACM Portal
      • arXiv
      • CiteSeerX
      • DBLP
      • DOAJ
      • Google Scholar
      • GVK
      • IEEEXplore
      • INSPIRE-HEP
      • MathSciNet
      • MEDLINE
      • SAO/NASA Astrophysics Data System
      • Springer
      • Unpaywall
      • zbMATH
    • Searching externally using Publication Identifiers
      • DiVA
      • DOI -- Digital Object Identifier
      • IACR eprint IDs
      • ISBN number
      • Medline
      • RFC document
      • SAO/NASA Astrophysics Data System
      • Title of the paper
    • Add unlinked PDFs including BibTeX data into the database
    • Synchronize file links
    • Cleanup entries
    • Save actions
    • Check integrity
    • Get BibTeX data from DOI
    • Find duplicates
    • Merge entries
    • Groups
    • Replace string
  • Import and Export
    • Import
      • JabRef Browser Extension
      • Custom import filters
      • Import from Microsoft Word -- MS Office Bibliography XML format
      • Import inspection window
      • New subdatabase based on AUX file
      • New entry from plain text
    • Export
      • Custom export filters
      • EndNote Export Filter
      • Export to an External SQL Database
      • Export to Microsoft Word -- MS Office Bibliography XML format
    • Other integrations
      • LaTeX Citations Tab
      • OpenOffice/LibreOffice integration
      • Pushing to external editor application
      • XMP metadata support in JabRef
    • Knowledge
      • Comparison of the Medline (txt), Medline (XML), and RIS format
  • Collaborative Work
    • Sharing a Bib(La)TeX Database
    • Shared SQL Database
    • Migration of pre-3.6 SQL databases into a shared SQL database
  • Configuration of JabRef
    • Customize the BibTeX key generator
    • Customize entry types
    • Customize general fields
    • Customize key bindings
    • Database properties window
    • Entry preview setup
    • Manage external file types
    • Manage protected terms
    • The string editor
  • Frequently Asked Questions and Howtos
    • General FAQs
    • Contributing
    • Sharing
    • How Tos
      • How to expand first names of a BibTeX entry
      • How to Improve the Help Page
      • How to translate the JabRef User Interface
    • FAQs on Operating Systems
      • Linux
      • Mac OS X
      • Windows
Powered by GitBook
On this page
  • Basics
  • Options
  • Help: -h
  • No-GUI mode: -n
  • Import file: -i filename[,import format]
  • Export file: -o filename[,export format]
  • Import BibTeX: -importBibtex
  • Export matching entries: -m [field]searchTerm,outputFile:file[,exportFormat]
  • Fetch entries from Web: -f=FetcherName:QueryString
  • Subdatabase from .aux file: -a infile[.aux],outfile[.bib] base-BibTeX-file
  • Set file links: -asfl
  • Regenerate keys: -g
  • Export preferences: -x filename
  • Import preferences: -p filename
  • Reset preferences: -d key
  • No files at startup: -b
  • Version: -v
  • Debug mode: --debug
  • Display output in the console: --console

Was this helpful?

Edit on GitHub
Export as PDF
  1. General information about JabRef

Command line use and options

PreviousBest PracticesNextAutomatic Backup (.sav and .bak) and Autosave

Last updated 3 years ago

Was this helpful?

Although JabRef is primarily a GUI based application, it offers several command line options that may be useful. JabRef can even perform file conversion operations without opening the graphical interface.

Basics

This description applies since JabRef 5.0, because JabRef comes with a pre-bundled Java-Runtime Environment

Locate JabRef.bat (Windows) or JabRef (Linux, Mac OS). In the partable versions, this is JabRef-5.0-portable_windows\JabRef\runtime\bin\JabRef.bat and JabRef-5.0-portable_linux\JabRef\lib\runtime\bin\JabRef.

Do not use JabRef\JabRef.exe or bin/JabRef

The following documentation is for Windows, but works equally well on Linux and Mac OS:

C:\portable-apps\JabRef-5.0-portable_windows\JabRef\runtime\bin\JabRef.bat[OPTIONS] [BIBTEX_FILE]

In some cases, you have to specify --console to ensure that output is written to the console.

You can always specify one or more BibTeX files to load by simply listing their filenames. Take care to specify all options before your list of file names. Ensure that the first file name is not misunderstood as being an argument for an option; this simply means that if a boolean option like -n or -l immediately precedes a file name, add the word true as an argument. For instance, the command line will correctly load the file original.bib, export it in to filetoexport.xml, and suppress the GUI_

C:\portable-apps\JabRef-5.0-portable_windows\JabRef\runtime\bin\JabRef.bat -o filetoexport.xml,docbook5 -n true original.bib

The word true prevents the file name from being interpreted as an argument to the -n option.

Options

Help: -h

(or --help)

Displays a summary of the command line options, including the list of available import and export formats.

No-GUI mode: -n

(or --nogui)

Suppresses the JabRef window (i.e. no GUI - Graphic User Interface - is displayed).

It causes the program to exit immediately once the command line options have been processed. This option is useful for performing file conversion operations from the command line or a script.

Import file: -i filename[,import format]

(or --import filename[,import format] or --importToOpen filename[,import format])

Import or load the file filename.

If only the filename is specified (or if the filename is followed by a comma and a * character), JabRef will attempt to detect the file format automatically. This works for BibTeX files, and also for all files in a supported import format. If the filename is followed by a comma and the name of an import format, the given import filter will be used.

Use the -h option to get the list of available import formats.

If an export option is also specified, the import will always be processed first, and the imported or loaded file will be used by the export filter. If the GUI is not suppressed (using the -n option), any imported or loaded file will show up in the main window.

If --importToOpen is used, the content of the file will be imported into the opened tab.

Note: The -i option can be specified only once, and for one file only.

Export file: -o filename[,export format]

(or --output filename[,export format]

Export or save a file imported or loaded by the same command line.

If a file is imported using the -i option, that file will be exported. If no -i option is used, the last file specified (and successfully loaded) will be exported.

If only filename is specified, it will be exported in BibTeX format. If the filename is followed by a comma and an export format, the given export filter will be used.

A custom export filter can be used, and will be preferred if the export name matches both a custom and a standard export filter.

If the GUI is not suppressed (using the -n option), any export operation will be performed before the JabRef window is opened, and the imported database will show up in the window.

Note: The -o option can be specified only once, and for one file only.

Xmp export option

The first option is to export all entries, which are included in the entries.bib file to the specified export.xmp file. The second argument, separated by comma, is the type of exporter used by JabRef.

JabRef.bat -o path\export.xmp,xmp  path\entries.bib -n

The second option is to export every entry in the entries.bib in a single .xmp file. Therefore, the file name is replaced by the keyword split without a file ending! JabRef generates individual .xmp files at the path location. The file name is a combination of the identifier provided by JabRef and the cite key of the entry.

JabRef.bat -o path\split,xmp  path\entries.bib -n

Import BibTeX: -importBibtex

Import or load code directly from the BibTeX file. This only works for BibTeX files, and does not support files of other import formats. If it detects this command line option, the JabRef CLI will take in its following argument as a BibTeX string that represents the BibTeX article file being read in for import (usually a filename). JabRef then passes on this information to a helper function that will parse the BibTex string into entries and return the resulting BibTex entries to the JabRef CLI.

If the GUI is not suppressed (using the -n option), any imported or loaded BibTeX file will show up in the main window.

Note: The -importBibtex option can be specified only once, and for one file only.

Export matching entries: -m [field]searchTerm,outputFile:file[,exportFormat]

(or --exportMatches [field]searchTerm,outputFile:file[,exportFormat])

Save to a new file all the database entries matching the given search term.

If the filename is followed by a comma and an export format, the given export filter will be used. Otherwise, the default format html-table (with Abstract and BibTeX, provided by tablerefsabsbib) is used.

Note: In addition it is also possible to search for entries within a time frame such as Year=1989-2005 (instead of only searching for entries of a certain year as in Year=2005).

Note: Search terms containing blanks need to be bracketed by quotation marks, as in (author=bock or title|keywords="computer methods")and not(author=sager)

Fetch entries from Web: -f=FetcherName:QueryString

(or --fetch=FetcherName:QueryString)

Query a Web fetcher and import the entries.

Pass both the name of a fetcher and your search term or paper id (e.g. --fetch=Medline:cancer), and the given fetcher will be run. Some fetchers will still display a GUI window if they need feedback from you.

The fetchers listed in the Web search panel can be run from the command line. To get the list of available fetchers, run --fetch without parameters.

Subdatabase from .aux file: -a infile[.aux],outfile[.bib] base-BibTeX-file

(or --aux infile[.aux],outfile[.bib] base-BibTeX-file)

Extract a subdatabase from a .aux file:

When you compile a LaTeX document (e.g. infile.tex), an .aux file is created (infile.aux). Among other things, it contains the list of entries used in your document. JabRef can extract the references used from the base-BibTeX-file to a new .bib file (outfile.bib). This way, you will have a subdatabase containing only the entries used in the .tex file.

Set file links: -asfl

(or --automaticallySetFileLinks)

Automatically set file links.

Regenerate keys: -g

(or --generateBibtexKeys)

Regenerate all keys for the entries of a BibTeX file.

Export preferences: -x filename

(or --prexp filename)

Export user preferences to an XML file. After exporting, JabRef will start normally.

Import preferences: -p filename

(or --primp filename)

Import user preferences from an XML file (exported using the -x option, or through the GUI). After importing, JabRef will start normally.

Reset preferences: -d key

(or --prdef key)

Reset preferences (key1, key2,..., or all).

No files at startup: -b

(or --blank)

Do not open any files at startup

Version: -v

(or --version)

Display the version number of JabRef.

Debug mode: --debug

Show debug level messages.

Display output in the console: --console

Show info and error messages in the console.

is an ISO standard for the creation, processing and interchange of standardized and custom metadata for digital documents and data sets.

Information about to the search function is given in .

XMP
'advanced search' documentation
docbook format
Help: -h
No-GUI mode: -n
Import file: -i filename[,import format]
Export file: -o filename[,export format]
Import BibTeX: -importBibtex
Export matching entries: -m [field]searchTerm,outputFile:file[,exportFormat]
Fetch entries from Web: -f=FetcherName:QueryString
Subdatabase from .aux file: -a infile[.aux],outfile[.bib] base-BibTeX-file
Set file links: -asfl
Regenerate keys: -g
Export preferences: -x filename
Import preferences: -p filename
Reset preferences: -d key
No files at startup: -b
Version: -v
Debug mode: --debug
Display output in the console: --console