Skip to content

Commit

Permalink
Merge pull request #252 from ericpre/add_pyqt_extra
Browse files Browse the repository at this point in the history
Add pyqt pip extra
  • Loading branch information
ericpre authored Apr 17, 2024
2 parents 1acadce + 174cbf9 commit e47abc5
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,6 @@ jobs:
sudo apt-get install libxcb-render-util0
sudo apt-get install libxcb-xinerama0
- name: Install Dependencies
run: |
pip install pyqt5 PyQtWebEngine
- name: Install HyperSpy (dev)
shell: bash
if: ${{ contains(matrix.HYPERSPY_VERSION, 'dev') }}
Expand All @@ -72,7 +68,7 @@ jobs:
- name: Install
shell: bash
run: |
pip install -e .[tests]
pip install -e .[all,tests]
- name: Pip list
run: |
Expand Down
10 changes: 5 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -69,18 +69,18 @@ and run the following command in the anaconda prompt:
Installation via pip
--------------------

HyperSpyUI can be intall from pip. Depending on your python distribution you may
need to have C compiler on your system to install some of the dependencies.
To install ``HyperSpyUI`` can be intalled from pypi.org including
optional dependencies (``exspy`` and ``pyqt5``)

.. code-block:: bash
pip install hyperspyui
pip install hyperspyui[all]
If pyqt is not installed, run:
To install ``HyperSpyUI`` with the minimum dependencies:

.. code-block:: bash
pip install PyQt5 PyQtWebEngine
pip install hyperspyui
Run HyperSpyUI
Expand Down
3 changes: 1 addition & 2 deletions doc/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ HyperSpyUI is on PyPI_, so simply run the command

.. code-block:: bash
pip install PyQt5 PyQtWebEngine
pip install hyperspyui
pip install hyperspyui[all]
which will download and install HyperSpyUI and its dependencies. The package defines
Expand Down
12 changes: 8 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -59,23 +59,27 @@ hyperspyui = "hyperspyui.__main__:main"
file = "COPYING.txt"

[project.optional-dependencies]
"all" = [
"exspy",
"hyperspyui[pyqt]",
]
"doc" = [
"sphinx > 5.2",
"sphinx_rtd_theme",
"sphinx-toggleprompt",
"sphinxcontrib-towncrier",
"towncrier",
]
"pyqt" = [
"PyQt5",
"PyQtWebEngine",
]
"tests" = [
"pytest-qt",
"pytest-cov",
"pytest-timeout",
"setuptools-scm",
]
"all" = [
"exspy[gui-jupyter]",
"exspy[gui-traitsui]"
]

[project.urls]
"Homepage" = "https://hyperspy.org/hyperspyui"
Expand Down
1 change: 1 addition & 0 deletions upcoming_changes/252.enhancements.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add ``pyqt`` pip extra to simplify installation.

0 comments on commit e47abc5

Please sign in to comment.