File tree 3 files changed +32
-23
lines changed
3 files changed +32
-23
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ # Build sdist and wheel
4
+ python -m pip install -U pip
5
+ python -m pip install build
6
+ python -m build
7
+
8
+ # Check sdist install and imports
9
+ mkdir -p test-sdist
10
+ cd test-sdist
11
+ python -m venv venv-sdist
12
+ venv-sdist/bin/python -m pip install ../dist/outlines-* .tar.gz
13
+ venv-sdist/bin/python -c " import outlines"
14
+ cd ..
15
+
16
+ # Check wheel install and imports
17
+ mkdir -p test-wheel
18
+ cd test-wheel
19
+ python -m venv venv-wheel
20
+ venv-wheel/bin/python -m pip install ../dist/outlines-* .whl
21
+ venv-wheel/bin/python -c " import outlines"
22
+ cd ..
Original file line number Diff line number Diff line change @@ -11,32 +11,11 @@ jobs:
11
11
steps :
12
12
- name : Checkout
13
13
uses : actions/checkout@v2
14
- - name : Set up Python
15
- uses : actions/setup-python@v2
16
- with :
17
- python-version : " 3.10"
18
- - name : Build sdist and wheel
19
- run : |
20
- python -m pip install -U pip
21
- python -m pip install build
22
- python -m build
14
+ - name : Build SDist and Wheel
15
+ run : ./.github/scripts/build_sdist_and_wheel.sh
23
16
- name : Check that the package version matches the Release name
24
17
run : |
25
18
grep -Rq "^Version: ${GITHUB_REF:10}$" outlines.egg-info/PKG-INFO
26
- - name : Check sdist install and imports
27
- run : |
28
- mkdir -p test-sdist
29
- cd test-sdist
30
- python -m venv venv-sdist
31
- venv-sdist/bin/python -m pip install ../dist/outlines-*.tar.gz
32
- venv-sdist/bin/python -c "import outlines"
33
- - name : Check wheel install and imports
34
- run : |
35
- mkdir -p test-wheel
36
- cd test-wheel
37
- python -m venv venv-wheel
38
- venv-wheel/bin/python -m pip install ../dist/outlines-*.whl
39
- venv-wheel/bin/python -c "import outlines"
40
19
- name : Publish to PyPi
41
20
uses : pypa/gh-action-pypi-publish@v1.4.2
42
21
with :
Original file line number Diff line number Diff line change 88
88
name : html-report
89
89
path : htmlcov
90
90
if : ${{ failure() }}
91
+
92
+ build-wheel :
93
+ name : Build Wheel and Test SDist
94
+ runs-on : ubuntu-latest
95
+ steps :
96
+ - uses : actions/checkout@v3
97
+ - name : Build SDist and Wheel
98
+ run : ./.github/scripts/build_sdist_and_wheel.sh
You can’t perform that action at this time.
0 commit comments