Minor readme fixes.
This commit is contained in:
parent
f10463a97c
commit
29e8fecfa9
34
readme.md
34
readme.md
@ -20,19 +20,19 @@ is supposed to do: help us do science, so now we are mostly doing that.
|
|||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
You can install the latest stable version of `pubs` through Pypi, with:
|
You can install the latest stable version of `pubs` through Pypi, with:
|
||||||
```
|
```shell
|
||||||
pip install pubs
|
pip install pubs
|
||||||
```
|
```
|
||||||
|
|
||||||
Alternatively, you can:
|
Alternatively, you can:
|
||||||
|
|
||||||
- install the latest development version with pip:
|
- install the latest development version with pip:
|
||||||
```
|
```shell
|
||||||
pip install --upgrade git+https://github.com/pubs/pubs
|
pip install --upgrade git+https://github.com/pubs/pubs
|
||||||
```
|
```
|
||||||
|
|
||||||
- clone the repository and install it manually:
|
- clone the repository and install it manually:
|
||||||
```
|
```shell
|
||||||
git clone https://github.com/pubs/pubs
|
git clone https://github.com/pubs/pubs
|
||||||
cd pubs
|
cd pubs
|
||||||
python setup.py install [--user]
|
python setup.py install [--user]
|
||||||
@ -44,32 +44,32 @@ Arch Linux users can also use the [pubs-git](https://aur.archlinux.org/packages/
|
|||||||
## Getting started
|
## Getting started
|
||||||
|
|
||||||
Create your library (by default, goes to `~/.pubs/`).
|
Create your library (by default, goes to `~/.pubs/`).
|
||||||
```
|
```shell
|
||||||
pubs init
|
pubs init
|
||||||
```
|
```
|
||||||
|
|
||||||
Import existing data from bibtex (pubs will try to automatically copy documents defined as 'file' in bibtex):
|
Import existing data from bibtex (pubs will try to automatically copy documents defined as 'file' in bibtex):
|
||||||
```
|
```shell
|
||||||
pubs import path/to/collection.bib
|
pubs import path/to/collection.bib
|
||||||
```
|
```
|
||||||
|
|
||||||
or for a .bib file containing a single reference:
|
or for a .bib file containing a single reference:
|
||||||
```
|
```shell
|
||||||
pubs add reference.bib -d article.pdf
|
pubs add reference.bib -d article.pdf
|
||||||
```
|
```
|
||||||
|
|
||||||
pubs can also automatically retrieve the bibtex from a doi:
|
pubs can also automatically retrieve the bibtex from a doi:
|
||||||
```
|
```shell
|
||||||
pubs add -D 10.1007/s00422-012-0514-6 -d article.pdf
|
pubs add -D 10.1007/s00422-012-0514-6 -d article.pdf
|
||||||
```
|
```
|
||||||
|
|
||||||
or an ISBN (dashes are ignored):
|
or an ISBN (dashes are ignored):
|
||||||
```
|
```shell
|
||||||
pubs add -I 978-0822324669 -d article.pdf
|
pubs add -I 978-0822324669 -d article.pdf
|
||||||
```
|
```
|
||||||
|
|
||||||
or an arXiv id (automatically downloading arXiv article is in the works):
|
or an arXiv id (automatically downloading arXiv article is in the works):
|
||||||
```
|
```shell
|
||||||
pubs add -X math/9501234 -d article.pdf
|
pubs add -X math/9501234 -d article.pdf
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -79,7 +79,7 @@ or an arXiv id (automatically downloading arXiv article is in the works):
|
|||||||
If you use latex, you can automatize references, by running `pubs export > references.bib` each time you update your library, which also fits well as a `makefile` rule.
|
If you use latex, you can automatize references, by running `pubs export > references.bib` each time you update your library, which also fits well as a `makefile` rule.
|
||||||
|
|
||||||
This ensures that your reference file is always up-to-date; you can cite a paper in your manuscript a soon as you add it in pubs. This means that if you have, for instance, a DOI on a webpage, you only need to do:
|
This ensures that your reference file is always up-to-date; you can cite a paper in your manuscript a soon as you add it in pubs. This means that if you have, for instance, a DOI on a webpage, you only need to do:
|
||||||
```
|
```shell
|
||||||
pubs add -D 10.1007/s00422-012-0514-6
|
pubs add -D 10.1007/s00422-012-0514-6
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -89,12 +89,12 @@ and then add `\cite{Loeb_2012}` in your manuscript. After exporting the bibliogr
|
|||||||
## Document management
|
## Document management
|
||||||
|
|
||||||
You can attach a document to a reference:
|
You can attach a document to a reference:
|
||||||
```
|
```shell
|
||||||
pubs doc add Loeb2012_downloaded.pdf Loeb_2012
|
pubs doc add Loeb2012_downloaded.pdf Loeb_2012
|
||||||
```
|
```
|
||||||
|
|
||||||
And open your documents automatically from the command line:
|
And open your documents automatically from the command line:
|
||||||
```
|
```shell
|
||||||
pubs doc open Loeb_2012
|
pubs doc open Loeb_2012
|
||||||
pubs doc open --with lp Loeb_2012 # Opens the document with `lp` to actually print it.
|
pubs doc open --with lp Loeb_2012 # Opens the document with `lp` to actually print it.
|
||||||
```
|
```
|
||||||
@ -114,18 +114,18 @@ You can then also conveniently interact with the git repository by using `pubs g
|
|||||||
## Multiple pubs Repositories
|
## Multiple pubs Repositories
|
||||||
|
|
||||||
You may want to have different pubs repositories, for different projects. To create an alternate repository:
|
You may want to have different pubs repositories, for different projects. To create an alternate repository:
|
||||||
```
|
```shell
|
||||||
pubs --config /path/to/config init --pubsdir /path/to/desired_repository_directory
|
pubs --config /path/to/config init --pubsdir /path/to/desired_repository_directory
|
||||||
```
|
```
|
||||||
The configuration file and repository will be automatically created.
|
The configuration file and repository will be automatically created.
|
||||||
|
|
||||||
Then you can add papers to the new repository:
|
Then you can add papers to the new repository:
|
||||||
```
|
```shell
|
||||||
pubs --config /path/to/config add -D 10.1007/s00422-012-0514-6
|
pubs --config /path/to/config add -D 10.1007/s00422-012-0514-6
|
||||||
```
|
```
|
||||||
|
|
||||||
A useful thing might be to define an alias in your shell:
|
A useful thing might be to define an alias in your shell:
|
||||||
```
|
```shell
|
||||||
alias pubs2="pubs --config /path/to/config"
|
alias pubs2="pubs --config /path/to/config"
|
||||||
```
|
```
|
||||||
and then use `pubs2` as you would use `pubs` directly. Note that you cannot use the alias plugin below to do this.
|
and then use `pubs2` as you would use `pubs` directly. Note that you cannot use the alias plugin below to do this.
|
||||||
@ -141,8 +141,8 @@ You can add custom commands to pubs by defining aliases in your configuration fi
|
|||||||
count = !pubs list -k "$@" | wc -l
|
count = !pubs list -k "$@" | wc -l
|
||||||
```
|
```
|
||||||
|
|
||||||
The first command defines a new subcommand: `pubs open --with evince` will be executed when `pubs evince` is typed.
|
The first configuration line defines a new subcommand: `pubs open --with evince` will be executed when `pubs evince` is typed.
|
||||||
The second starts with a bang: `!`, and is treated as a shell command. If other arguments are provided they are passed to the shell command as in a script. In the example above the `count` alias can take arguments that are be passed to the `pubs list -k` command, hence enabling filters like `pubs count year:2012`.
|
The second starts with a bang: `!`, which means that it is treated as a shell command. If other arguments are provided they are passed to the shell command as in a script. In the example above the `count` alias can take arguments that are passed over to the `pubs list -k` command, hence enabling filters like `pubs count year:2012`.
|
||||||
|
|
||||||
|
|
||||||
## Autocompletion
|
## Autocompletion
|
||||||
|
Loading…
x
Reference in New Issue
Block a user