Skip to content

Commit

Permalink
Merge #332: Mark pyside2 as optional and update dependencies
Browse files Browse the repository at this point in the history
3d43984 Use set -ex in all bash scripts (Andrew Chow)
edcee23 fix generate-ui.sh for GNU sed (Andrew Chow)
7e65e2f Use qt extra when generating releases (Andrew Chow)
619b412 Update setup.py (Andrew Chow)
f8b40cd Add qt extra to make pyside2 optional (Andrew Chow)
7bfcff7 Update dependencies (Andrew Chow)

Pull request description:

  Marks pyside2 as optional and part of an extra `qt`. In doing so, the dependencies in the poetry.lock file are also updated. `setup.py` is regenerated to pick up this change.

  Closes #331

Top commit has no ACKs.

Tree-SHA512: dee9aaf793c29125d2f0537f64d8a69e21e668bec5bdcac42dfb8148660f178c10d9d940bfe10454f2315d1df5fb2a07301890635b0fa069977964326eb78b44
  • Loading branch information
achow101 committed May 27, 2020
2 parents b970ba7 + 3d43984 commit 2c4d8b3
Show file tree
Hide file tree
Showing 8 changed files with 274 additions and 74 deletions.
4 changes: 3 additions & 1 deletion contrib/build_bin.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#! /bin/bash
# Script for building standalone binary releases deterministically

set -ex

eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
pip install -U pip
pip install poetry

# Setup poetry and install the dependencies
poetry install
poetry install -E qt

# We now need to remove debugging symbols and build id from the hidapi SO file
so_dir=`dirname $(dirname $(poetry run which python))`/lib/python3.6/site-packages
Expand Down
4 changes: 3 additions & 1 deletion contrib/build_dist.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#! /bin/bash
# Script for building pypi distribution archives deterministically

set -ex

eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
pip install -U pip
pip install poetry

# Setup poetry and install the dependencies
poetry install
poetry install -E qt

# Make the distribution archives for pypi
poetry build -f wheel
Expand Down
4 changes: 2 additions & 2 deletions contrib/build_wine.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
# Script which sets up Wine and builds the Windows standalone binary

set -e
set -ex

PYTHON_VERSION=3.6.8

Expand Down Expand Up @@ -67,7 +67,7 @@ TZ=UTC find ${lib_dir} -name '*.py' -type f -execdir touch -t "201901010000.00"
# Install python dependencies
POETRY="wine $PYHOME/Scripts/poetry.exe"
sleep 5 # For some reason, pausing for a few seconds makes the next step work
$POETRY install
$POETRY install -E qt

# make the ui files
pushd hwilib/ui
Expand Down
4 changes: 3 additions & 1 deletion contrib/generate-ui.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
#! /bin/bash

set -ex

pushd hwilib/ui
for file in *.ui
do
gen_file=ui_`echo $file| cut -d. -f1`.py
pyside2-uic $file -o $gen_file
sed -i '' -e 's/raise()/raise_()/g' $gen_file
sed -i'' -e 's/raise()/raise_()/g' $gen_file
done
popd
4 changes: 2 additions & 2 deletions contrib/generate_setup.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#! /bin/bash
# Generates the setup.py file

set -e
set -ex

# Setup poetry and install the dependencies
poetry install
poetry install -E qt

# Build the source distribution
poetry build -f sdist
Expand Down
Loading

0 comments on commit 2c4d8b3

Please sign in to comment.