Skip to content

Commit

Permalink
Use snake_case for module_names
Browse files Browse the repository at this point in the history
  • Loading branch information
lukin0110 committed Dec 20, 2024
1 parent ea161c2 commit f588651
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[tool.poetry] # https://python-poetry.org/docs/pyproject/
name = "zapman"
version = "0.0.1"
description = "A Python tool for API testing and development in your terminal."
description = "An API Client for the terminal. A Python CLI for API testing and development."
authors = []
license = "Proprietary"
readme = "README.md"
Expand Down
4 changes: 2 additions & 2 deletions src/zapman/_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
from pathlib import Path
from types import ModuleType

from orval import kebab_case
from orval import snake_case


def __module_name(file_path: str) -> str:
relative = Path(file_path).relative_to(Path.cwd())
results = [kebab_case(part) for part in relative.parts]
results = [snake_case(part) for part in relative.parts]
if relative.is_file() or relative.suffix:
results[-1] = relative.stem
return ".".join(results)
Expand Down

0 comments on commit f588651

Please sign in to comment.