Skip to content

Commit

Permalink
chore(pipelines): fix packaging
Browse files Browse the repository at this point in the history
  • Loading branch information
portellaa committed Aug 1, 2023
1 parent e9d8fc7 commit 4158bb7
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 11 deletions.
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -456,5 +456,5 @@ xcuserdata/

# Extra
bin/
*__version__
*/__version__
*__version__*
*/__version__*
8 changes: 4 additions & 4 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
include *.txt
include *.md

excluse .editorconfig
excluse .flake8
exclude .editorconfig
exclude .flake8
exclude .gitignore
excluse .pre-commit-config.yaml
exclude .pre-commit-config.yaml
exclude .releaserc.json
exclude Makefile
excluse renovate.json
exclude renovate.json
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ install-all:
define BUILD
find . -name "*.pyi" -delete && rm -rf build dist && \
echo version = \"$(version)\" > $1/__version__.py && \
stubgen . --export-less && \
stubgen . -o . --export-less && \
$(PYTHON) -m build --wheel
twine check dist/*
endef
Expand All @@ -44,13 +44,13 @@ endef

define WHEEL
cd dist && \
mv $(subst -,_,$1)-$(version)-py3-none-any.whl $(subst -,_,$1)-$(version)-py$(PYV)-none-any.whl && \
$(PYTHON) -m pyc_wheel $(subst -,_,$1)-$(version)-py$(PYV)-none-any.whl --exclude "__version__.py" && \
mv $1-$(version)-py3-none-any.whl $1-$(version)-py$(PYV)-none-any.whl && \
$(PYTHON) -m pyc_wheel $1-$(version)-py$(PYV)-none-any.whl --exclude "__version__.py" && \
twine check *
endef

build:
$(call BUILD,sketch-dask-extension)
$(call BUILD,sketch_dask_extension)

lint:
pre-commit run --all-files
Expand All @@ -59,4 +59,4 @@ upload:
$(call UPLOAD)

wheel:
$(call WHEEL,sketch-dask-extension)
$(call WHEEL,sketch_dask_extension)
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,6 @@ packaging = [
"pyc_wheel",
"mypy",
]

[tool.setuptools.dynamic]
version = { attr = "sketch_dask_extension.__version__" }
4 changes: 4 additions & 0 deletions sketch_dask_extension/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
try:
from .__version__ import version as __version__
except:
__version__ = "0.0.0.dev0"

0 comments on commit 4158bb7

Please sign in to comment.