Skip to content

Commit ebbd1a9

Browse files
authored
Merge pull request #368 from DigitalSlideArchive/revert-using-hatch
Revert using hatchling
2 parents 71cf1fb + 0474feb commit ebbd1a9

File tree

6 files changed

+80
-64
lines changed

6 files changed

+80
-64
lines changed

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,3 @@ ENV/
5151

5252
node_modules/
5353
.eslintcache
54-
55-
histomicsui/_version.py

MANIFEST.in

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
include LICENSE
2+
include README.rst
3+
include setup.py
4+
5+
graft histomicsui
6+
graft docs
7+
prune test
8+
global-exclude *.py[co] *.cmake __pycache__ node_modules

pyproject.toml

Lines changed: 0 additions & 58 deletions
This file was deleted.

setup.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[bdist_wheel]
2+
universal = 1

setup.py

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
import os
2+
3+
from setuptools import find_packages, setup
4+
5+
with open('README.rst') as readme_file:
6+
readme = readme_file.read()
7+
8+
9+
def prerelease_local_scheme(version):
10+
"""
11+
Return local scheme version unless building on master in CircleCI.
12+
13+
This function returns the local scheme version number
14+
(e.g. 0.0.0.dev<N>+g<HASH>) unless building on CircleCI for a
15+
pre-release in which case it ignores the hash and produces a
16+
PEP440 compliant pre-release version number (e.g. 0.0.0.dev<N>).
17+
"""
18+
from setuptools_scm.version import get_local_node_and_date
19+
20+
if os.getenv('CIRCLE_BRANCH') in ('master', ):
21+
return ''
22+
else:
23+
return get_local_node_and_date(version)
24+
25+
26+
setup(
27+
name='histomicsui',
28+
use_scm_version={'local_scheme': prerelease_local_scheme, 'fallback_version': '0.0.0'},
29+
setup_requires=['setuptools-scm'],
30+
description='Organize, visualize, and analyze histology images.',
31+
author='Kitware, Inc.',
32+
author_email='kitware@kitware.com',
33+
classifiers=[
34+
'Development Status :: 5 - Production/Stable',
35+
'License :: OSI Approved :: Apache Software License',
36+
'Natural Language :: English',
37+
'Programming Language :: Python :: 3',
38+
'Programming Language :: Python :: 3.8',
39+
'Programming Language :: Python :: 3.9',
40+
'Programming Language :: Python :: 3.10',
41+
'Programming Language :: Python :: 3.11',
42+
'Programming Language :: Python :: 3.12',
43+
],
44+
install_requires=[
45+
'girder-large-image-annotation>=1.25.0',
46+
'girder-slicer-cli-web>=1.4.0',
47+
'cachetools',
48+
'orjson',
49+
],
50+
extras_require={
51+
'analysis': [
52+
'girder-slicer-cli-web[girder]>=1.2.3',
53+
],
54+
},
55+
license='Apache Software License 2.0',
56+
long_description=readme,
57+
long_description_content_type='text/x-rst',
58+
include_package_data=True,
59+
keywords='girder-plugin, histomicsui',
60+
packages=find_packages(exclude=['test', 'test.*']),
61+
url='https://github.com/DigitalSlideArchive/histomicsui',
62+
zip_safe=False,
63+
python_requires='>=3.8',
64+
entry_points={
65+
'girder.plugin': [
66+
'histomicsui = histomicsui:GirderPlugin',
67+
],
68+
},
69+
)

tox.ini

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,15 +82,12 @@ passenv =
8282
TWINE_USERNAME
8383
TWINE_PASSWORD
8484
TWINE_REPOSITORY_URL
85-
allowlist_externals =
86-
git
85+
CIRCLE_BRANCH
8786
deps =
8887
build
8988
twine
9089
commands =
91-
git status
9290
python -m build
93-
git status
9491
twine check dist/*
9592
twine upload --skip-existing dist/*
9693

0 commit comments

Comments
 (0)