Skip to content

Commit

Permalink
Setting up pypi upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Oli4 committed Feb 10, 2021
1 parent b6833a1 commit 88a6a33
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 24 deletions.
7 changes: 6 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ python:
- 3.7
- 3.6
- 3.5
- 2.7

# Command to install dependencies, e.g. pip install -r requirements.txt --use-mirrors
install: pip install -U tox-travis
Expand All @@ -27,3 +26,9 @@ deploy:
tags: true
repo: Oli4/eyepy
python: 3.7

after_success:
- git config --global user.name "semantic-release (via TravisCI)"
- git config --global user.email "semantic-release@travis"
- pip install python-semantic-release
- semantic-release publish
14 changes: 9 additions & 5 deletions eyepy/core/drusen.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,15 @@ def filter(self, drusen_map):
def find(self, oct_obj):
drusen_map = np.zeros(oct_obj.shape, dtype=bool)
for i, scan in enumerate(oct_obj):
drusen_map[..., i] = drusen(
scan.layers["RPE"], scan.layers["BM"], scan.shape,
degree=self.degree, iterations=self.iterations,
outlier_threshold=self.outlier_threshold,
poly_fit_type=self.poly_fit_type)
try:
drusen_map[..., i] = drusen(
scan.layers["RPE"], scan.layers["BM"], scan.shape,
degree=self.degree, iterations=self.iterations,
outlier_threshold=self.outlier_threshold,
poly_fit_type=self.poly_fit_type)
except KeyError as e:
print(e)

return drusen_map


Expand Down
15 changes: 3 additions & 12 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,15 +1,6 @@
[bumpversion]
current_version = 0.1.0
commit = True
tag = True

[bumpversion:file:setup.py]
search = version='{current_version}'
replace = version='{new_version}'

[bumpversion:file:eyepy/__init__.py]
search = __version__ = '{current_version}'
replace = __version__ = '{new_version}'
[semantic_release]
version_variable = setup.py:__version__
upload_to_pypi = True

[bdist_wheel]
universal = 1
Expand Down
17 changes: 11 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,15 @@
# -*- coding: utf-8 -*-

"""The setup script."""

__version__ = "0.1.4"
from setuptools import find_packages, setup
import sys

try:
from semantic_release import setup_hook
setup_hook(sys.argv)
except ImportError:
pass

with open("README.rst") as readme_file:
readme = readme_file.read()
Expand All @@ -27,7 +34,7 @@
setup(
author="Olivier Morelle",
author_email="oli4morelle@gmail.com",
python_requires=">2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*",
python_requires=">=3.5",
classifiers=[
"Development Status :: 2 - Pre-Alpha",
"Intended Audience :: Developers",
Expand All @@ -40,7 +47,6 @@
"Programming Language :: Python :: 3.8",
],
description="The Python package for working with ophthalmological data.",
entry_points={"console_scripts": ["eyepy=eyepy.cli:main"]},
install_requires=requirements,
license="MIT license",
long_description=readme + "\n\n" + history,
Expand All @@ -52,6 +58,5 @@
test_suite="tests",
tests_require=test_requirements,
url="https://github.com/MedVisBonn/eyepy",
version="0.1.1",
zip_safe=False,
)
version=__version__,
zip_safe=False,)

0 comments on commit 88a6a33

Please sign in to comment.