Skip to content

Commit 09e666e

Browse files
authored
Bump version to 0.0.2. Add packaging workflow (#167)
* Add packaging and publishing workflow * Fix package dependencies (thank you, CI!) * Bump version to 0.0.2
1 parent b8c675b commit 09e666e

File tree

5 files changed

+49
-8
lines changed

5 files changed

+49
-8
lines changed

.github/workflows/linting.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: CI
1+
name: Lint
22
on:
33
pull_request:
44
jobs:

.github/workflows/packaging.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Packaging
2+
on:
3+
release:
4+
types: [ created ]
5+
push:
6+
branches: [ 'master' ]
7+
pull_request:
8+
jobs:
9+
deploy:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- uses: actions/setup-python@v2
14+
- name: Install Python dependencies
15+
run: |
16+
python -m pip install -U pip
17+
python -m pip install setuptools wheel twine build
18+
19+
- name: Build Python package
20+
run: python -m build --sdist --wheel --outdir dist/ .
21+
22+
- name: Install Python package
23+
run: python -m pip install dist/*.whl
24+
25+
- name: Test that exocc runs
26+
run: exocc -o tmp --stem conv apps/x86_demo/conv/conv.py
27+
28+
- name: Show generated C code (manual inspection for now)
29+
run: cat tmp/conv.c
30+
31+
# Will only run on release.
32+
- name: Publish distribution to PyPI
33+
if: startsWith(github.ref, 'refs/tags')
34+
uses: pypa/gh-action-pypi-publish@master
35+
with:
36+
password: ${{ secrets.PYPI_API_TOKEN }}

setup.cfg

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,12 @@ packages = find:
3737
package_dir =
3838
=src
3939
install_requires =
40-
PySMT==0.9.0
41-
asdl-adt==0.1.0
42-
astor==0.8.1
43-
numpy==1.21.2
44-
yapf==0.31.0
40+
PySMT>=0.9
41+
asdl-adt>=0.1,<0.2
42+
astor>=0.8
43+
numpy>=1.21.2
44+
yapf>=0.31
45+
z3-solver>=4.8.12.0
4546

4647
[options.packages.find]
4748
where = src

src/exo/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from .memory import Memory, DRAM
66
from . import query_asts as QAST
77

8-
__version__ = '0.0.1'
8+
__version__ = '0.0.2'
99

1010
__all__ = [
1111
"LoopIR_pprint",

tox.ini

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,13 @@ envlist = py39
33

44
[testenv]
55
deps =
6+
# This list is maintained separately from requirements.txt to make it
7+
# harder to accidentally forget a package dependency in setup.cfg.
8+
Pillow
69
pytest
710
pytest-cov
8-
-r{toxinidir}/requirements.txt
11+
scipy
12+
torch
913
commands = pytest --cov=./ --cov-report=xml
1014
passenv =
1115
SDE_PATH

0 commit comments

Comments
 (0)