Skip to content

Commit

Permalink
Update versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
jmp1985 committed Oct 20, 2022
1 parent aaf43f8 commit 43d4e2f
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,6 @@ _skbuild/

# Ignore ctags
tags

# setuptools_scm
_version.py
1 change: 0 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
[metadata]
name = python-multem
version = 0.3.0

description = A Python wrapper for MULTEM
long_description = file: README.md
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,12 @@ def main():
package_dir={"": "src"},
packages=find_packages(where="src"),
install_requires=["numpy"],
setup_requires=["pytest-runner"],
setup_requires=["setuptools_scm", "pytest-runner"],
tests_require=tests_require,
test_suite="tests",
ext_modules=[Extension("multem_ext", [])],
cmdclass={"build_ext": CMakeBuild},
use_scm_version={"write_to": "src/multem/_version.py"},
extras_require={
"build_sphinx": ["sphinx", "sphinx_rtd_theme"],
"test": tests_require,
Expand Down
8 changes: 8 additions & 0 deletions src/multem/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@
# This code is distributed under the GPLv3 license, a copy of
# which is included in the root directory of this package.
#


try:
from multem._version import version as __version__
except ImportError:
__version__ = "unknown"


import numpy
from multem_ext import * # noqa

Expand Down

0 comments on commit 43d4e2f

Please sign in to comment.