Installation ----------- .. note:: - tardisbase and TARDIS ecosystem packages are only supported on macOS and GNU/Linux. Windows users can run TARDIS ecosystem packages using `WSL `_ or on a Virtual Machine. - TARDIS ecosystem package dependencies are distributed only through the `conda `_ package management system, therefore installation requires `Anaconda `_ or `Miniconda `_ to be installed on your system. Conda lockfiles are platform-specific dependency files that produce reproducible environments. We strongly recommend installing `tardisbase` using this method by following the steps below. .. note:: You need not install the environment if you have installed it already beforehand when installing a different TARDIS ecosystem package. 1. Download the lockfile for your platform: .. code-block:: bash wget -q https://github.com/tardis-sn/tardisbase/master/conda-{platform}-64.lock Replace ``{platform}`` with ``linux-64`` or ``osx-arm64`` based on your operating system. 2. Create the environment: .. code-block:: bash conda create --name tardis --file conda-{platform}.lock 3. Activate the environment: .. code-block:: bash conda activate tardis .. note:: This environment works for all TARDIS ecosystem packages. No additional environments are required. 4. To install `tardisbase` first execute these commands: .. code-block:: bash $ git clone git@github.com:tardis-sn/tardisbase.git $ cd tardisbase $ git remote add upstream git@github.com:tardis-sn/tardisbase.git $ git fetch upstream $ git checkout upstream/master The installation process differs for developers and non-developers: a. Developers should `fork the repository `_ , configure GitHub to `work with SSH keys `_, set up the `upstream remote `_ and `origin` (pointing to your fork), and install `tardisbase` in development mode. .. code-block:: bash $ pip install -e . b. Non-developers can install from specific releases using pip: .. code-block:: bash $ pip install git+https://github.com/tardis-sn/tardisbase.git@{tag} For example, to install the latest release: .. code-block:: bash $ pip install git+https://github.com/tardis-sn/tardisbase.git@release-latest or to install the most recent, unreleased changes from upstream: .. code-block:: bash $ pip install git+https://github.com/tardis-sn/tardisbase.git@master Environment update ================== To update the environment, download the latest lockfile and run ``conda update``. .. code-block:: bash $ wget -q https://github.com/tardis-sn/tardisbase/master/conda-{platform}-64.lock $ conda update --name tardis --file conda-{platform}.lock .. note:: If you have installed `tardisbase` in development mode, you should *ideally* update your environment whenever you pull latest code because the new code added might be using updated (or new) dependencies. If you don't do that and your installation seems broken, you can check if your environment requires update by comparing it against the latest environment file: .. code-block:: bash $ conda compare --name tardis env.yml We also recommend updating optional dependencies whenever you pull latest code. **Recommended approach:** We highly recommend deleting your existing environment and creating a new one using the latest lockfile whenever you need to update your environment. Use the following ``conda`` command to remove your current ``tardis`` environment: .. code-block:: bash $ conda remove --name tardis --all