diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8d3ae5b..9eeed08 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -75,6 +75,7 @@ jobs: - uses: conda-incubator/setup-miniconda@v3 with: miniconda-version: "latest" + channels: "conda-forge" - name: conda setup run: | conda install -y anaconda-client @@ -121,7 +122,7 @@ jobs: - name: Install package run: python -m pip install dist/*.whl - name: Import package - run: python -c "import $PACKAGE; print($PACKAGE.__version__)" + run: python -c "import $PACKAGE; print($PACKAGE._version.__version__)" pip_publish: name: Publish PyPI diff --git a/scripts/conda/build.sh b/scripts/conda/build.sh index 00f5cac..b1c3b4f 100755 --- a/scripts/conda/build.sh +++ b/scripts/conda/build.sh @@ -4,13 +4,11 @@ set -euxo pipefail PACKAGE="spatialpandas" -python -m build -w . +python -m build --sdist . VERSION=$(python -c "import $PACKAGE; print($PACKAGE._version.__version__)") export VERSION -# conda config --env --set conda_build.pkg_format 2 -conda build scripts/conda/recipe --no-anaconda-upload --no-verify +conda build scripts/conda/recipe --no-anaconda-upload --no-verify -c conda-forge --package-format 1 -# mv "$CONDA_PREFIX/conda-bld/noarch/$PACKAGE-$VERSION-py_0.conda" dist mv "$CONDA_PREFIX/conda-bld/noarch/$PACKAGE-$VERSION-py_0.tar.bz2" dist diff --git a/scripts/conda/recipe/meta.yaml b/scripts/conda/recipe/meta.yaml index 8302186..bb3338a 100644 --- a/scripts/conda/recipe/meta.yaml +++ b/scripts/conda/recipe/meta.yaml @@ -6,11 +6,11 @@ package: version: {{ VERSION }} source: - url: ../../../dist/{{ project["name"] }}-{{ VERSION }}-py3-none-any.whl + url: ../../../dist/{{ project["name"] }}-{{ VERSION }}.tar.gz build: noarch: python - script: {{ PYTHON }} -m pip install --no-deps -vv {{ project["name"] }}-{{ VERSION }}-py3-none-any.whl + script: {{ PYTHON }} -m pip install --no-deps -vv . entry_points: {% for group,epoints in project.get("entry_points",{}).items() %} {% for entry_point in epoints %}