Skip to content

Commit

Permalink
DIST: single-source version w/o breaking pip install -e .
Browse files Browse the repository at this point in the history
  • Loading branch information
kohr-h committed Apr 29, 2019
1 parent b8443f6 commit e83332f
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 17 deletions.
5 changes: 5 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
include CONTRIBUTING.md
include LICENSE
include README.md
include VERSION
include setup.cfg
include setup.py
include odl/pytest.ini
exclude .*
recursive-include odl/test test*.py *test.py
prune conda
prune doc
prune examples
prune tools
1 change: 1 addition & 0 deletions VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.0.0.dev0
39 changes: 24 additions & 15 deletions odl/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,32 @@
"""

from __future__ import absolute_import

from os import pardir, path

import numpy as np

__version__ = '1.0.0.dev0'
__all__ = ('set',
'space',
'operator',
'discr',
'contrib',
'deform',
'diagnostics',
'phantom',
'solvers',
'tomo',
'trafos',
'ufunc_ops',
'util',
)
__all__ = (
'set',
'space',
'operator',
'discr',
'contrib',
'deform',
'diagnostics',
'phantom',
'solvers',
'tomo',
'trafos',
'ufunc_ops',
'util',
)

# Set package version
curdir = path.abspath(path.dirname(__file__))

with open(path.join(curdir, pardir, 'VERSION')) as version_file:
__version__ = version_file.read().strip()

# Set old Numpy printing behavior as to not invalidate all doctests.
# TODO(kohr-h): switch to new behavior when Numpy 1.14 is minimum
Expand Down
5 changes: 3 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = odl
version = attr: odl.__version__
version = file: VERSION
description = Operator Discretization Library
long_description = file: README.md
long_description_content_type = text/markdown
Expand Down Expand Up @@ -38,6 +38,7 @@ classifiers =
[options]
packages = find:
install_requires =
setuptools >=39.2.0
future >=0.14
packaging >=15.0
numpy >=1.10,!=1.14.0,!=1.14.1,!=1.14.2
Expand All @@ -51,7 +52,7 @@ include_package_data = True

[options.packages.find]
exclude =
docs
doc
examples

[options.package_data]
Expand Down

0 comments on commit e83332f

Please sign in to comment.