Installation
Get the Code
Clone the code and documentation repository from GitHub with:
$ git clone git@github.com:UBC-MOAD/Reshapr.git
or copy the URI (the stuff after git clone above) from the Code button on the repository page.
Note
The git clone command above assumes that your are connecting to GitHub using SSH. If it fails, please follow the instructions in our Secure Remote Access docs to set up your SSH keys and Copy Your Public ssh Key to GitHub.
Conda Environment and Package Installation
Running Reshapr
in an isolated Conda environment using is highly recommended.
Assuming that you have Miniconda3 installed,
you can create and activate an environment called reshapr that will have
all of the Python packages necessary use Reshapr
,
and install the package with the commands below.
$ cd Reshapr
$ conda env create -f envs/environment-user.yaml
$ conda activate reshapr
Reshapr
is installed in editable install mode as part of the conda environment
creation process.
That means that the package is installed from the cloned repo via symlinks so that
it will be automatically updated as the repo evolves.
Please see Updating Your Installation for more details.
You can confirm that you have successfully installed Reshapr
by typing reshapr in your activated environment.
You should see the top level command help information and the list of available
Reshapr Sub-commands.
You can show the version of Reshapr
that you have installed
and other important information with:
(reshapr)$ reshapr info
To deactivate the environment use:
(reshapr)$ conda deactivate
Note
If you want to make code changes in the Reshapr
package,
please see Reshapr Package Development for information on how to work in
the package development environment.
If you want to use Reshapr
in a different Conda environment,
edit your environment description to include the packages listed in the
dependencies: section of envs/environment-user.yaml
,
then update your environment and install Reshapr
with:
(your-env)$ conda env update -f your-env-yaml
(your-env)$ python3 -m pip install --editable path/to/Reshapr
Updating Your Installation
In general,
all you need to do to update your Reshapr
installation is pull the latest updates
from GitHub:
$ cd Reshapr
$ conda activate reshapr
(reshapr)$ git pull
You may also need to do:
(reshapr)$ python3 -m pip install --editable .
to complete the update if there have been new Reshapr Sub-commands or options added since your last update.
Uninstalling
If you want to uninstall Reshapr
,
you can remove the Conda environment with:
$ conda env remove -n reshapr
You can remove your clone of the repository with:
$ cd Reshapr/..
$ rm -rf Reshapr/