Skip to content

Commit

Permalink
Fix versioning with scm (#60)
Browse files Browse the repository at this point in the history
* Fix versioning with scm

* keep the git history

* keep the git history

* fix pip install in order to install the build dependencies

* fix pip install in order to install the build dependencies

* move build section from setup.cfg to setup.py
  • Loading branch information
xmnlab authored Nov 21, 2021
1 parent 5635606 commit 43f1b4f
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 4 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ jobs:
steps:
- name: checkout
uses: actions/checkout@v1
with:
fetch-depth: 0

- name: setup conda
uses: conda-incubator/setup-miniconda@v2
Expand All @@ -44,10 +46,10 @@ jobs:
- name: install dependencies
run: |
if [[ "${{ matrix.pyomnisci-version }}" == "dev" ]]; then
python -m pip install --no-deps git+https://github.com/omnisci/pyomnisci.git
python -m pip install git+https://github.com/omnisci/pyomnisci.git
python -m pip install git+https://github.com/ibis-project/ibis.git
fi
python -m pip install --no-deps -e .
python -m pip install -e .
- name: show environment
run: conda list
Expand Down Expand Up @@ -84,7 +86,7 @@ jobs:

- name: install dependencies
run: |
python -m pip install --no-deps -e .
python -m pip install -e .
pre-commit install
- name: show environment
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:

steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0

- uses: conda-incubator/setup-miniconda@v2
with:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# scm versioning
ibis_omniscidb/_version.py

*.swp
*.pyc
__pycache__
Expand Down
5 changes: 5 additions & 0 deletions ibis_omniscidb/tests/test_package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import ibis_omniscidb


def test_versioning():
assert ibis_omniscidb.__version__ not in (None, "", "0.0.0")
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
[build-system]
requires = ["setuptools", "wheel", "setuptools_scm"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
write_to = "ibis_omniscidb/_version.py"

[tool.black]
line-length = 79
skip-string-normalization = true
Expand Down
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
'pyarrow',
'rbc-project>=0.4.0',
],
setup_requires=['setuptools_scm'],
use_scm_version=True,
classifiers=[
'Development Status :: 4 - Beta',
Expand Down

0 comments on commit 43f1b4f

Please sign in to comment.