diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce8a4f2..d9e9b8c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,13 +35,13 @@ jobs: run: pip install -e ".[dev]" - name: Lint (ruff) - run: ruff check src/typerform + run: ruff check src/pytypeform - name: Type-check (mypy) - run: mypy src/typerform + run: mypy src/pytypeform - name: Test (pytest + coverage) - run: pytest --cov=typerform --cov-report=xml --cov-report=term-missing + run: pytest --cov=pytypeform --cov-report=xml --cov-report=term-missing - name: Upload coverage if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.12' diff --git a/README.md b/README.md index 50711b9..5a56ae8 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,11 @@ A Type-Safe UI/CLI Generator powered by Pydantic and Prompt-Toolkit. -[![PyPI version](https://img.shields.io/pypi/v/typerform.svg)](https://pypi.org/project/typerform/) -[![Python](https://img.shields.io/pypi/pyversions/typerform.svg)](https://pypi.org/project/typerform/) -[![CI](https://github.com/sthitaprajnas/typerform/actions/workflows/ci.yml/badge.svg)](https://github.com/sthitaprajnas/typerform/actions/workflows/ci.yml) +[![PyPI version](https://img.shields.io/pypi/v/pytypeform.svg)](https://pypi.org/project/pytypeform/) +[![Python](https://img.shields.io/pypi/pyversions/pytypeform.svg)](https://pypi.org/project/pytypeform/) +[![CI](https://github.com/sthitaprajnas/pytypeform/actions/workflows/ci.yml/badge.svg)](https://github.com/sthitaprajnas/pytypeform/actions/workflows/ci.yml) [![License](https://img.shields.io/badge/license-Apache%202.0-green)](LICENSE) -[![Typed](https://img.shields.io/badge/typing-py.typed-informational)](src/typerform/py.typed) +[![Typed](https://img.shields.io/badge/typing-py.typed-informational)](src/pytypeform/py.typed) Typerform transforms your Pydantic models into professional, interactive CLI wizards. Stop writing boilerplate input loops and manual validation—let your schemas drive the user experience. @@ -26,7 +26,7 @@ Typerform transforms your Pydantic models into professional, interactive CLI wiz ## Installation ```bash -pip install typerform +pip install pytypeform ``` ## Quick Start @@ -34,7 +34,7 @@ pip install typerform ```python from typing import Literal from pydantic import BaseModel, Field -from typerform import form +from pytypeform import form class SetupConfig(BaseModel): project_name: str = Field(description="Project Name", min_length=3) @@ -90,12 +90,12 @@ config = form(MyModel, hydrate_from=[os.environ]) Contributions are welcome! Whether it's bug reports, feature requests, or new prompt engines. ```bash -git clone https://github.com/sthitaprajnas/typerform.git -cd typerform +git clone https://github.com/sthitaprajnas/pytypeform.git +cd pytypeform pip install -e ".[dev]" pytest # run test suite -ruff check src/typerform # lint -mypy src/typerform # type-check +ruff check src/pytypeform # lint +mypy src/pytypeform # type-check ``` ## License diff --git a/examples/collection_wizard.py b/examples/collection_wizard.py index 1d7cdf6..c7a115d 100644 --- a/examples/collection_wizard.py +++ b/examples/collection_wizard.py @@ -5,7 +5,7 @@ # Add src to sys.path sys.path.insert(0, "./src") -from typerform import form +from pytypeform import form from rich.console import Console console = Console() diff --git a/examples/enterprise_wizard.py b/examples/enterprise_wizard.py index 88c5eeb..36281a0 100644 --- a/examples/enterprise_wizard.py +++ b/examples/enterprise_wizard.py @@ -5,7 +5,7 @@ # Add the src directory to sys.path sys.path.insert(0, "./src") -from typerform import form +from pytypeform import form from rich.console import Console console = Console() diff --git a/examples/simple_wizard.py b/examples/simple_wizard.py index ecef558..be1ba55 100644 --- a/examples/simple_wizard.py +++ b/examples/simple_wizard.py @@ -3,12 +3,12 @@ from pydantic import BaseModel, EmailStr, Field -# Add the src directory to sys.path so we can import typerform without installing it +# Add the src directory to sys.path so we can import pytypeform without installing it sys.path.insert(0, "./src") from rich.console import Console -from typerform import form +from pytypeform import form console = Console() diff --git a/examples/ultimate_demo.py b/examples/ultimate_demo.py index d3608bb..4a2139e 100644 --- a/examples/ultimate_demo.py +++ b/examples/ultimate_demo.py @@ -6,7 +6,7 @@ # Add src to sys.path sys.path.insert(0, "./src") -from typerform import form +from pytypeform import form from rich.console import Console console = Console() diff --git a/examples/ultimate_wizard.py b/examples/ultimate_wizard.py index 9e146ee..fe402fb 100644 --- a/examples/ultimate_wizard.py +++ b/examples/ultimate_wizard.py @@ -6,7 +6,7 @@ # Add src to sys.path sys.path.insert(0, "./src") -from typerform import form +from pytypeform import form from rich.console import Console console = Console() diff --git a/pyproject.toml b/pyproject.toml index fa23ea7..532dbd4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ build-backend = "hatchling.build" # --------------------------------------------------------------------------- [project] -name = "typerform" +name = "pytypeform" version = "0.2.0" description = "A Type-Safe UI/CLI Generator powered by Pydantic." readme = "README.md" @@ -47,10 +47,10 @@ dependencies = [ ] [project.urls] -Homepage = "https://github.com/sthitaprajnas/typerform" -Repository = "https://github.com/sthitaprajnas/typerform" -Documentation = "https://github.com/sthitaprajnas/typerform#readme" -Issues = "https://github.com/sthitaprajnas/typerform/issues" +Homepage = "https://github.com/sthitaprajnas/pytypeform" +Repository = "https://github.com/sthitaprajnas/pytypeform" +Documentation = "https://github.com/sthitaprajnas/pytypeform#readme" +Issues = "https://github.com/sthitaprajnas/pytypeform/issues" [project.optional-dependencies] dev = [ @@ -67,7 +67,7 @@ dev = [ # --------------------------------------------------------------------------- [tool.hatch.build.targets.wheel] -packages = ["src/typerform"] +packages = ["src/pytypeform"] [tool.hatch.build.targets.sdist] include = [ @@ -89,7 +89,7 @@ addopts = "-v --tb=short" [tool.mypy] strict = true python_version = "3.10" -files = ["src/typerform"] +files = ["src/pytypeform"] [tool.ruff] line-length = 100 @@ -100,7 +100,7 @@ select = ["E", "F", "I", "UP", "B", "SIM"] ignore = ["E501"] [tool.coverage.run] -source = ["src/typerform"] +source = ["src/pytypeform"] [tool.coverage.report] show_missing = true diff --git a/src/typerform/__init__.py b/src/pytypeform/__init__.py similarity index 100% rename from src/typerform/__init__.py rename to src/pytypeform/__init__.py diff --git a/src/typerform/core.py b/src/pytypeform/core.py similarity index 100% rename from src/typerform/core.py rename to src/pytypeform/core.py diff --git a/src/typerform/__pycache__/__init__.cpython-313.pyc b/src/typerform/__pycache__/__init__.cpython-313.pyc deleted file mode 100644 index d77c0e2..0000000 Binary files a/src/typerform/__pycache__/__init__.cpython-313.pyc and /dev/null differ diff --git a/src/typerform/__pycache__/core.cpython-313.pyc b/src/typerform/__pycache__/core.cpython-313.pyc deleted file mode 100644 index dc70351..0000000 Binary files a/src/typerform/__pycache__/core.cpython-313.pyc and /dev/null differ diff --git a/tests/test_core.py b/tests/test_core.py index 9158d92..4b547ba 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -4,8 +4,8 @@ from unittest.mock import MagicMock from pydantic import BaseModel, Field, SecretStr -from typerform import form -from typerform.core import PromptEngine, set_engine, config +from pytypeform import form +from pytypeform.core import PromptEngine, set_engine, config import io from rich.console import Console diff --git a/tests/test_extended.py b/tests/test_extended.py index 971f6ab..45bf75c 100644 --- a/tests/test_extended.py +++ b/tests/test_extended.py @@ -2,8 +2,8 @@ from typing import Literal, Optional, Any, Dict from enum import Enum from pydantic import BaseModel, Field, SecretStr -from typerform import form -from typerform.core import PromptEngine, set_engine, config +from pytypeform import form +from pytypeform.core import PromptEngine, set_engine, config import io from rich.console import Console