Skip to content

Commit

Permalink
merge master -Dorg -Ssuccess-only: PR 156 (Use versioneer for tagging (
Browse files Browse the repository at this point in the history
…Fix ome#154))
  • Loading branch information
snoopycrimecop committed Jan 3, 2024
2 parents 6353e50 + b243a8d commit a4d2e79
Show file tree
Hide file tree
Showing 9 changed files with 3,071 additions and 29 deletions.
20 changes: 0 additions & 20 deletions .bumpversion.cfg

This file was deleted.

1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
src/omero_zarr/_version.py export-subst
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,3 @@ venv/
build/
dist/
__pycache__
src/omero_zarr/_version.py
9 changes: 5 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ repos:
rev: v4.5.0
hooks:
- id: trailing-whitespace
exclude: .bumpversion.cfg
- id: end-of-file-fixer
- id: check-json
files: \.(json)$
Expand All @@ -48,6 +47,7 @@ repos:
rev: 6.1.0
hooks:
- id: flake8
exclude: versioneer.py
additional_dependencies: [
flake8-blind-except,
flake8-builtins,
Expand All @@ -66,18 +66,19 @@ repos:
rev: v1.7.1
hooks:
- id: mypy
exclude: "(setup.py|versioneer.py|tests/)"
# This is for checking tests/* (everything else has a stricter check
# below), but since there's no include it's run on everything

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.7.1
hooks:
- id: mypy
exclude: "(setup.py|versioneer.py)"
args: [
--disallow-untyped-defs,
--ignore-missing-imports,
"--disallow-untyped-defs",
"--ignore-missing-imports"
]
exclude: tests/

- repo: https://github.com/adrienverge/yamllint.git
rev: v1.33.0
Expand Down
7 changes: 7 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[versioneer]
VCS = git
style = pep440
versionfile_source = src/omero_zarr/_version.py
versionfile_build =
tag_prefix = v
parentdir_prefix = src/omero_zarr/
8 changes: 5 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@

from setuptools import setup

import versioneer


def get_long_description() -> str:
here = os.path.abspath(os.path.dirname(__file__))
Expand All @@ -29,10 +31,12 @@ def get_long_description() -> str:


long_description = get_long_description()
version = versioneer.get_version()

setup(
name="omero-cli-zarr",
version="0.5.5.dev0",
version=version,
cmdclass=versioneer.get_cmdclass(),
packages=["omero_zarr", "omero.plugins"],
package_dir={"": "src"},
description="Plugin for exporting images in zarr format.",
Expand All @@ -55,6 +59,4 @@ def get_long_description() -> str:
long_description=long_description,
keywords=["OMERO.CLI", "plugin"],
url="https://github.com/ome/omero-cli-zarr/",
setup_requires=["setuptools_scm"],
use_scm_version={"write_to": "src/omero_zarr/_version.py"},
)
5 changes: 4 additions & 1 deletion src/omero_zarr/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,13 @@

from ome_zarr.format import CurrentFormat

from ._version import version as __version__
from . import _version

ngff_version = CurrentFormat().version

__all__ = [
"__version__",
]


__version__ = _version.get_versions()["version"]
Loading

0 comments on commit a4d2e79

Please sign in to comment.