bibman

command module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 1, 2022 License: GPL-2.0, GPL-3.0 Imports: 9 Imported by: 0

README

bibman

Description

A simple bibliography manager. bibman is a simpler and less feature-rich alternative to applications like papis.

It uses the crossref and datacite apis to search for citations using the DOI.

Features:

  • Manually add citations
  • Import citations via doi (crossref/datacite api)
  • Import citations via bibtex
  • Export of bibtex
  • TUI manager
  • Linking a file to a citation
  • Neovim telescope plugin code

Usage

USAGE: bibman [flag] <args>
  For more help visit: https://codeberg.org/KMIJPH/bibman
FLAGS:
  -help	show this message
  -a	<doi> <file> add citation (if no doi specified, add manually)
  -b	prints bibliography in bibtex format to stdout
  -i	imports bibtex from stdin
  -j	prints (simplified) bibliography in json format to stdout
  -t	launch tui

Examples

Adding a citation:

# add manually
EDITOR=nvim bibman -a
# add via doi
bibman -a "10.1126/science.1155121"
# add a file
bibman -a "10.1126/science.1155121" bonan.pdf

Importing via bibtex:

cat test.bib | bibman -i

Exporting to bibtex:

bibman -b > test.bib

Launch tui:

EDITOR=nvim bibman -t

Installation

make install

or check out the makefile to do it manually.

Build-time dependencies:
  • golang >= 1.18
Runtime dependencies
  • none

Further information

Bibtex

bibman supports the biblatex specification. It is assumed that biber or any other biblatex compatible bibliography processor is used.

Files

When adding a file to the -a command, bibman copies the file to: $HOME/.local/share/bibliography, which is also bibman's directory for storing its database. On Windows and Mac it will use golang's os.UserCacheDir.

A new filename is given to the file, using author, year and title of the citation. If no file is passed, bibman will link a filename anyway. This makes adding a file after the creation of the citation easier.

Import

When importing via bibtex, bibman assumes a reasonably well formatted .bib file. The parsing is not very sophisticated and uses simple regex.

For examples see here.

Neovim plugin

The code for the neovim telescope plugin can be found here. It is the users job to source the file in init.lua.

Editing citations

bibman uses the EDITOR environmental variable to edit citations. To change the editor, pass a new EDITOR value (see examples).

Tui

bibman provides a TUI to edit the citation database with VIM-like keybindings.

For a list of keybindings and commands type :help in TUI mode.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL