The PyXLL command line tool automates tasks around installing, updating and switching between different versions of PyXLL.
In order to use the PyXLL command line tool you first need to install it using pip:
>> pip install pyxll
If you are using a conda or virtual env you should activate the environment you want to use first.
To get the latest version of the PyXLL command line too you should update the package using pip:
>> pip install --upgrade pyxll
The PyXLL wheel file is also included in the PyXLL download and may be installed from there.
After installing, the following commands are available:
The install command installs the PyXLL Excel add-in into Excel. It is necessary to either perform this step or to install PyXLL manually before the PyXLL Excel add-in can be used.
>> pyxll install [OPTIONS] [PATH]
Options: | |
---|---|
--version |
Version of PyXLL to install. |
--debug / -d |
Output more information when running the command. |
Can be run with or without PATH.
If you already have PyXLL installed you will be warned but may continue.
PyXLL will be configured automatically to use the active Python environment.
Further configuration can be performed by editing the pyxll.cfg file included in the installation or by using the pyxll configure command.
The configure command opens the pyxll.cfg configuration file for the currently active PyXLL addin.
>> pyxll configure [OPTIONS]
Options: | |
---|---|
--debug / -d |
Output more information when running the command. |
The status command checks the status of the active PyXLL installation and reports information about it.
>> pyxll status [OPTIONS]
Options: | |
---|---|
--debug / -d |
Output more information when running the command. |
If there are any issues with your current PyXLL installation this command may help identify what the problem is.
The update command updates your active PyXLL installation to the latest version of PyXLL.
>> pyxll update [OPTIONS] [PATH]
Options: | |
---|---|
--version |
Version of PyXLL to update to. |
--force |
For the update, even if the installed version is newer. |
--debug / -d |
Output more information when running the command. |
The activate command switches between different PyXLL installations quickly.
>> pyxll activate [OPTIONS] [PATH]
Options: | |
---|---|
--debug / -d |
Output more information when running the command. |
--non-interactive / -ni |
Don’t prompt the user for any input. [#ni] |
Installs the PyXLL certificate into the ‘Trusted Publishers’ certificate store.
>> pyxll install-certificate [OPTIONS]
Options: | |
---|---|
--debug / -d |
Output more information when running the command. |
Installing the certificate is done as part of installing PyXLL but can also be done using this command (for example, if installing the certificate failed during the initial install).
If the certificate can’t be installed then Excel may prompt the user that the add-in is unsafe or prevent it from loading, depending on Excel’s Trust Center Settings.
The uninstall command uninstalls the PyXLL Add-In from Excel.
>> pyxll uninstall
Options: | |
---|---|
--force |
Uninstall without any confirmation. |
--dry-run |
Log what would happen without actually uninstalling. |
--debug / -d |
Output more information when running the command. |
Footnotes
[#ni]
The --non-interactive
option is new in PyXLL 5.3.0 and enables pyxll activate
to be used from
a script more easily for automated deployment of PyXLL environments.