====================
Installing licenses
====================

You can install licenses for :doc:`Accelerate </accelerate/index>`,
:doc:`IOPro </iopro/index>` or
:doc:`MKL Optimizations </mkl-optimizations/index>` with the graphical
:ref:`Anaconda Navigator license manager <license-install-gui>`, and
you can install licenses for these and all other products
:ref:`from the command line <license-install-manual>`.

Before you start
================

* You should have installed conda and received your license by email from your sales representative.
* If want to use Navigator, it needs to be installed. Both Navigator and conda are included in Anaconda.
* Optionally, your products or a free trial may already be installed.
* Save the license file to your ``Downloads`` folder (or directory). To save a few steps, make a note of the filename now.
* If you need help, contact your sales rep or priority support.


.. _license-install-gui:

Using Navigator to install a license
====================================

The graphical Navigator license manager allows you to add, remove and
view details of licensed packages.

#. Open :doc:`Navigator <../../navigator/index>`.

#. In the **Help** menu, select License Manager.

#. Click the Add license button, and then select the license file:

   .. figure:: /img/license-manager.png

      ..

   |

#. Click the Close button.

#. After you install the license, :ref:`update conda and install the product <license-update-install>`.

#. :ref:`Run the product <license-running>`.

If you have questions about or problems with a license,
click the Got a problem with your license? link, contact
your `sales rep <mailto:sales@anaconda.com>`_ or contact
`priority support <https://support.continuum.io/>`_ for assistance.


.. _license-install-manual:

Using the command line to install a license
=============================================

Licenses for all Anaconda user products are stored in the home folder in a
hidden subfolder named ``~/.continuum``. The license directory is hidden to
help protect your license files from accidental changes or deletion. The
following installation procedures describe how to manage hidden directories for
your operating system.

TIP: The conda command ``conda info --license`` shows you the location of your license files
and validates those licenses.

Command line procedures:

* :ref:`win-license`.
* :ref:`osx-license`.
* :ref:`nix-license`.
* :ref:`license-update-install`.
* :ref:`license-running`.
* :ref:`license-problem`.


.. _win-license:

Windows
-------

Hidden folders appear in Windows Explorer only if the Show hidden files and
folders option is enabled. To bypass this issue, use the Anaconda prompt, and if
the hidden ``.continuum`` folder has not been created yet, make one as discussed
below. Then copy the license file into the hidden license folder.

#. Open a terminal window.

#. To see the files in your home folder, run the command ``dir``.

#. In the output list, look for ``.continuum``.

   If you do not see a folder named ``.continuum``, make a new one with ``mkdir .continuum``.

#. Find the license file in your ``Downloads`` folder or other folder where you
   saved the file::

      dir Downloads

   NOTE: Replace ``Downloads`` with the name of the folder where you saved your license file.

#. Copy the license file into the ``.continuum`` directory::

      copy Downloads\license_bundle_1234.txt .continuum

   NOTE: Replace ``license_bundle_1234.txt`` with the name of your license file.

#. :ref:`Update conda and install the product <license-update-install>`.

#. :ref:`Run the product <license-running>`.

Your license is now installed on Windows. If you have any questions or
problems, please contact your `sales rep <mailto:sales@anaconda.com>`_ or
`priority support <https://support.continuum.io/>`_ for assistance.


.. _osx-license:

macOS
-----

Use Finder to locate the hidden licenses folder. If the folder has not
been created yet, make one as discussed below. Then copy and paste the license
into the hidden folder.

#. Look for the hidden folder:

   #. In the bottom row of icons, click the Finder icon.

   #. In the **Go** menu, select Go to folder.

   #. In the box that appears, type ``~/.continuum``, and then click the Go button.

   #. If the search results listing is empty, make a new hidden licenses folder by
      selecting New Folder in the **File** menu and then typing ``~/.continuum``.

#. Copy the license file:

   #. Go to your ``Downloads`` folder or wherever you saved the license file.
   #. Highlight the license filename.
   #. In the **Edit** menu, select Copy File.

#. Return to the licenses directory:

   #. In the **Go** menu, select Go to folder.
   #. In the box that appears, type ``~/.continuum``, and then click the Go Button.

#. Paste in the license file:

   #. In the file listing, double-click the ``~/.continuum`` folder to open the folder.

   #. In the top menu bar, in the **Edit** menu, select Paste Item.

#. :ref:`Update conda and install the product <license-update-install>`.

#. :ref:`Run the product <license-running>`.

Your license is now installed on macOS. If you have any questions or
problems, please contact your `sales rep <mailto:sales@anaconda.com>`_ or
`priority support <https://support.continuum.io/>`_ for assistance.


.. _nix-license:

Linux
-----

Use the List-All command to display all directories including hidden ones,
and if a license directory has not been created yet, make one as discussed
below. Then copy the license into the hidden license directory.

#. Open a terminal window.

#. To see the files in your home folder, run the command ``ls -a``.

#. In the output list, look for ``.continuum``.

   If you do not see a folder named ``.continuum``, make a new one with ``mkdir .continuum``.

#. Find the license file in your ``Downloads`` folder
   or other folder where you saved the file::

      cd Downloads
      ls

   NOTE: Replace ``Downloads`` with the name of the folder where you saved your license file.

   If the list is long run::

      ls | more

#. Highlight the filename, and then in the **Edit** menu, select Copy.

#. Copy the license file into the ``.continuum`` directory::

      cp license_bundle_1234.txt ~/.continuum

   NOTE: Replace ``license_bundle_1234.txt`` with the name of your license file.

   TIP: Instead of typing the file name, you can paste it into the command:

   #. Type ``cp``.
   #. In the **Edit** menu, select Paste to paste in the license filename.
   #. Type ``~/.continuum``.
   #. Press Enter.

#. :ref:`Update conda and install the product <license-update-install>`.

#. :ref:`Run the product <license-running>`.

Your license is now installed on Linux. If you have any questions or
problems, please contact your `sales rep <mailto:sales@anaconda.com>`_ or
`priority support <https://support.continuum.io/>`_ for assistance.


.. _license-update-install:

Updating conda and installing a product--all operating systems
-----------------------------------------------------------------

NOTE: If you previously installed a 30-day trial, you may skip this procedure,
but running it again is harmless.

To update conda and install a product:

1) In a terminal window, run::

    conda update conda
    conda install your_package_name

   NOTE: Replace ``your_package_name`` with the actual name of your package or
   product, such as ``accelerate``. Follow the full installation instructions for
   the product.


.. _license-running:

Running your new packages or products--all operating systems
---------------------------------------------------------------

#. Start Python::

      python

   If you have multiple versions of Python on your computer,
   make sure that the startup message says it is Anaconda Python.

#. Import your newly licensed packages or products::

      import your_package_name

   NOTE: Replace ``your_package_name`` with the actual name of your package or
   product, such as ``accelerate``. Follow the full installation instructions for
   the product.


.. _license-problem:

If you have problems
--------------------

If you have any questions or problems, please contact your `sales rep <mailto:sales@anaconda.com>`_ or `priority support <https://support.continuum.io/>`_ for assistance.
