Skip to content

Commit f86acd8

Browse files
committed
Change the local build strategy
Signed-off-by: Artyom Vancyan <[email protected]>
1 parent ec424ca commit f86acd8

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
- name: Install dependencies
6767
run: |
6868
pip install --upgrade pip
69-
python -m pip install -e .
69+
sh build.sh
7070
pip install tox tox-gh-actions
7171
- name: Run tests using tox
7272
run: tox -e ${{ matrix.env }}

build.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/bin/bash
2+
3+
# last version of `build` supporting Python 3.6
4+
pip install build==0.9.0
5+
6+
# build the wheel and install it
7+
WHEEL_NAME=$(python -m build | grep -Po "django_mermaid-.*\.whl" | tail -n 1)
8+
pip install dist/$WHEEL_NAME

tox.ini

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ deps =
1717
django21: django<2.2
1818
django11: django<2.0
1919
-r{toxinidir}/tests/requirements.txt
20+
allowlist_externals = sh
2021
commands =
21-
pip install -e .
22+
sh build.sh
2223
pytest

0 commit comments

Comments
 (0)