Installation
Using pip
The easiest way of installing papis is using the PyPi
repositories and
the package manager pip3
, just open a terminal and type in
pip3 install papis
If you are on GNU/Linux like systems you might need to type sudo
sudo pip3 install papis
or if you prefer installing it locally then simply type
pip3 install --user papis
You can also update papis with pip
pip3 install --upgrade papis
Archlinux
NixOS
If you are running NixOS or you have the nix package manager installed, you can install papis by running:
nix-env -i papis
If you like papis, just clone the repository
git clone git@github.com:papis/papis.git
cd papis
and start hacking it with:
nix-shell --expr 'with import <nixpkgs> {}; papis.overrideDerivation (drv: { src = ./.; })'
This command will provide you a shell with all the dependencies required.
From source
First of all you have to get the code, open a terminal and hit
git clone https://github.com/papis/papis.git
or download the zip file.
Go inside of the papis
source folder and you can install it with python3
.
The general command that you have to hit is by using the setup.py
script:
python3 setup.py install
Again, if you want to install it locally because you don’t have administrative rights on your computer you simply type
python3 setup.py install --user
If you want to work on the code, you can alternatively hit
python3 setup.py develop --user
Warning
If you install the package locally, the program papis
will be installed
by default into your ~/.local/bin
directory, so that you will have to
set your PATH
accordingly.
One way of doing this in bash
shells (Linux
and the like, also
Ubuntu
on Windows or cygwin
) is by adding the following line to your
~/.bashrc
file
export PATH=$PATH:$HOME/.local/bin
Requirements
Papis needs the following packages that are sometimes not installed with the
system python3
distribution
python3-setuptools
However if you have a general enough python distribution they should be installed.
Running tests
In order to run the necessary tests to submit a pull request, make sure that the following commands pass
python -m pytest papis/ tests/ --cov=papis
python -m mypy papis
python -m flake8 papis
for it, make sure that you have pytest
, flake8
and mypy
installed.
You can make sure that you have everything you need to run the tests by doing in the root directory
pip install .[develop]
this command installs the necessary dependencies for developing
and running the tests. Look inside of the file setup.py
for
further information.
You can also look at the folder tools
for scripts used in the
CI testing phase for further context.