File tree Expand file tree Collapse file tree 3 files changed +8
-35
lines changed
src/geant4_python_application Expand file tree Collapse file tree 3 files changed +8
-35
lines changed Original file line number Diff line number Diff line change 1515
1616 pull_request :
1717 push :
18- branches :
19- [main]
18+ branches : [main]
2019
21- # # Paste this snippet into the workflow file to enable tmate debugging
20+ # # Paste this snippet into the workflow file to enable tmate debugging
2221 # - name: Setup tmate session
2322 # uses: mxschmitt/action-tmate@v3
2423 # if:
@@ -170,6 +169,7 @@ jobs:
170169 - name : pip install the package
171170 run : |
172171 python -m pip install .[test]
172+ python -c "import geant4_python_application; print(geant4_python_application.version)"
173173
174174 # test ability to download datasets in one job and use the cache in the others
175175 - name : Cache Geant4 Datasets
Original file line number Diff line number Diff line change @@ -5,34 +5,7 @@ if (NOT DEFINED SKBUILD_PROJECT_NAME)
55 set (SKBUILD_PROJECT_NAME geant4-python-application)
66endif ()
77
8- if (NOT DEFINED SKBUILD_PROJECT_VERSION)
9- # IDE
10- set (SKBUILD_PROJECT_VERSION 0.0.0.ide)
11- endif ()
12-
13- string (REGEX MATCHALL "[^.]+" SKBUILD_PROJECT_VERSION_COMPONENTS
14- "${SKBUILD_PROJECT_VERSION} " )
15- list (GET SKBUILD_PROJECT_VERSION_COMPONENTS 0 SKBUILD_PROJECT_VERSION_MAJOR)
16- list (GET SKBUILD_PROJECT_VERSION_COMPONENTS 1 SKBUILD_PROJECT_VERSION_MINOR)
17- list (GET SKBUILD_PROJECT_VERSION_COMPONENTS 2 SKBUILD_PROJECT_VERSION_PATCH)
18- list (LENGTH SKBUILD_PROJECT_VERSION_COMPONENTS version_components_length)
19- if (version_components_length GREATER 3)
20- list (GET SKBUILD_PROJECT_VERSION_COMPONENTS 3
21- SKBUILD_PROJECT_VERSION_SUFFIX)
22- else ()
23- set (SKBUILD_PROJECT_VERSION_SUFFIX "" )
24- endif ()
25-
26- # join version components (cannot put suffix in 'project')
27- string (
28- CONCAT SKBUILD_PROJECT_VERSION_NO_SUFFIX ${SKBUILD_PROJECT_VERSION_MAJOR}
29- "." ${SKBUILD_PROJECT_VERSION_MINOR} "."
30- ${SKBUILD_PROJECT_VERSION_PATCH} )
31-
32- project (
33- ${SKBUILD_PROJECT_NAME}
34- LANGUAGES CXX
35- VERSION ${SKBUILD_PROJECT_VERSION_NO_SUFFIX} )
8+ project (${SKBUILD_PROJECT_NAME} LANGUAGES CXX)
369
3710set (PYTHON_MODULE_NAME _geant4_application)
3811
Original file line number Diff line number Diff line change 11from __future__ import annotations
22
33from geant4_python_application ._geant4_application import (
4- __doc__ ,
5- __version__ ,
64 awkward_version ,
75 geant4_version ,
86 pybind11_version ,
97)
8+ from geant4_python_application ._version import version , version_tuple
109from geant4_python_application .application import Application
1110from geant4_python_application .detector import Detector
1211from geant4_python_application .files .datasets import data_directory , install_datasets
1312from geant4_python_application .files .directories import application_directory
1413from geant4_python_application .gdml import basic_gdml
1514
16- version = __version__
15+ __version__ = version
16+ __version__tuple__ = version_tuple
1717
1818__all__ = [
19- "__doc__" ,
2019 "__version__" ,
20+ "__version__tuple__" ,
2121 "geant4_version" ,
2222 "awkward_version" ,
2323 "pybind11_version" ,
You can’t perform that action at this time.
0 commit comments