mirror of
https://github.com/katanemo/plano.git
synced 2026-06-20 15:28:07 +02:00
fix tests
This commit is contained in:
parent
bcaa26ed71
commit
8d61316948
3 changed files with 13 additions and 1 deletions
|
|
@ -0,0 +1,3 @@
|
||||||
|
"""Plano CLI - Intelligent Prompt Gateway."""
|
||||||
|
|
||||||
|
__version__ = "0.4.0"
|
||||||
|
|
@ -50,10 +50,16 @@ ARCHGW_DOCKERFILE = "./Dockerfile"
|
||||||
|
|
||||||
def get_version():
|
def get_version():
|
||||||
try:
|
try:
|
||||||
|
# First try to get version from package metadata (for installed packages)
|
||||||
version = importlib.metadata.version("planoai")
|
version = importlib.metadata.version("planoai")
|
||||||
return version
|
return version
|
||||||
except importlib.metadata.PackageNotFoundError:
|
except importlib.metadata.PackageNotFoundError:
|
||||||
return "version not found"
|
# Fallback to version defined in __init__.py (for development)
|
||||||
|
try:
|
||||||
|
from planoai import __version__
|
||||||
|
return __version__
|
||||||
|
except ImportError:
|
||||||
|
return "version not found"
|
||||||
|
|
||||||
|
|
||||||
@click.group(invoke_without_command=True)
|
@click.group(invoke_without_command=True)
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,9 @@ planoai = "planoai.main:main"
|
||||||
requires = ["hatchling"]
|
requires = ["hatchling"]
|
||||||
build-backend = "hatchling.build"
|
build-backend = "hatchling.build"
|
||||||
|
|
||||||
|
[tool.hatch.version]
|
||||||
|
path = "planoai/__init__.py"
|
||||||
|
|
||||||
[tool.hatch.build.targets.wheel]
|
[tool.hatch.build.targets.wheel]
|
||||||
packages = ["planoai"]
|
packages = ["planoai"]
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue