()
| 63 | |
| 64 | # Get version from command line or __init__.py |
| 65 | def get_version(): |
| 66 | # If version was provided via command line, use that |
| 67 | if version is not None: |
| 68 | return version |
| 69 | |
| 70 | # Otherwise, fall back to reading from __init__.py |
| 71 | import re |
| 72 | |
| 73 | version_file = os.path.join(project_root, "mirix", "__init__.py") |
| 74 | with open(version_file, "r", encoding="utf-8") as version_f: |
| 75 | version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", version_f.read(), re.M) |
| 76 | if version_match: |
| 77 | return version_match.group(1) |
| 78 | raise RuntimeError("Unable to find version string.") |
| 79 | |
| 80 | |
| 81 | # Client-specific dependencies (minimal) |
no test coverage detected