convashun 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,36 @@
1
+ name: Continuous Integration
2
+
3
+ on:
4
+ push:
5
+ branches: [ main, develop ]
6
+ pull_request:
7
+ branches: [ main, develop ]
8
+
9
+ jobs:
10
+ test:
11
+ name: Test on ${{ matrix.os }} (Python ${{ matrix.python-version }})
12
+ runs-on: ${{ matrix.os }}
13
+ strategy:
14
+ fail-fast: false
15
+ matrix:
16
+ os: [ubuntu-latest, windows-latest, macos-latest]
17
+ python-version: ["3.10", "3.11", "3.12"]
18
+
19
+ steps:
20
+ - name: Checkout Code
21
+ uses: actions/checkout@v4
22
+
23
+ - name: Install uv
24
+ uses: astral-sh/setup-uv@v5
25
+ with:
26
+ enable-cache: true
27
+ version: "latest"
28
+
29
+ - name: Set up Python ${{ matrix.python-version }}
30
+ run: uv python install ${{ matrix.python-version }}
31
+
32
+ - name: Install Dependencies
33
+ run: uv sync --all-extras --dev
34
+
35
+ - name: Run Test Suite
36
+ run: uv run pytest
@@ -0,0 +1,34 @@
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - 'v*'
7
+
8
+ jobs:
9
+ validate:
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: actions/checkout@v4
13
+ - uses: astral-sh/setup-uv@v5
14
+ - run: uv sync --dev
15
+ - run: uv run pytest
16
+
17
+ publish:
18
+ needs: validate
19
+ runs-on: ubuntu-latest
20
+ environment: release
21
+ permissions:
22
+ id-token: write # Mandatory configuration rule for PyPI Trusted Publishers OIDC authentication
23
+ contents: write
24
+ steps:
25
+ - uses: actions/checkout@v4
26
+
27
+ - name: Install uv
28
+ uses: astral-sh/setup-uv@v5
29
+
30
+ - name: Build Package Distributions
31
+ run: uv build
32
+
33
+ - name: Upload Package Distributions to PyPI
34
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,10 @@
1
+ # Python-generated files
2
+ __pycache__/
3
+ *.py[oc]
4
+ build/
5
+ dist/
6
+ wheels/
7
+ *.egg-info
8
+
9
+ # Virtual environments
10
+ .venv
@@ -0,0 +1,17 @@
1
+ repos:
2
+ # 1. Standard out-of-the-box file sanity checkers
3
+ - repo: https://github.com/pre-commit/pre-commit-hooks
4
+ rev: v4.6.0
5
+ hooks:
6
+ - id: trailing-whitespace # Trims unnecessary trailing spaces
7
+ - id: end-of-file-fixer # Ensures files end with a clean newline
8
+ - id: check-yaml # Validates your GitHub Actions workflow syntax
9
+ - id: check-added-large-files # Prevents accidentally committing giant data files
10
+
11
+ # 2. Ruff: The lightning-fast Python formatter and linter
12
+ - repo: https://github.com/astral-sh/ruff
13
+ rev: v0.4.4
14
+ hooks:
15
+ - id: ruff # Runs linting checks (catches unused imports, variables, bugs)
16
+ args: [ --fix ] # Automatically auto-fixes safe lint issues
17
+ - id: ruff-format # Auto-formats your code rules to match PEP 8 style standards
@@ -0,0 +1 @@
1
+ 3.12
@@ -0,0 +1,24 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+ We, as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, caste, color, religion, or sexual identity and orientation.
5
+
6
+ We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
7
+
8
+ ## Our Standards
9
+ Examples of behavior that contributes to a positive environment include:
10
+ * Demonstrating empathy and kindness toward other people
11
+ * Being respectful of differing opinions, viewpoints, and experiences
12
+ * Giving and gracefully accepting constructive feedback
13
+ * Accepting responsibility and apologizing to those affected by our mistakes
14
+
15
+ Examples of unacceptable behavior include:
16
+ * The use of sexualized language or imagery, and unwelcome sexual attention or advances
17
+ * Trolling, insulting or derogatory comments, and personal or political attacks
18
+ * Public or private harassment
19
+ * Publishing others' private information without explicit permission
20
+
21
+ ## Enforcement Responsibilities
22
+ Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
23
+
24
+ [ Read the full framework text at https://contributor-covenant.org ]
@@ -0,0 +1,27 @@
1
+ # Contributing to convashun 🟢
2
+
3
+ Thank you for checking out `convashun`! We welcome contributions from developers, technical writers, and the engineering community-including our peers at Aurora Robotics.
4
+
5
+ Follow these guardrails to ensure your pull requests are reviewed and merged quickly.
6
+
7
+ ## Code Style Guide
8
+ To keep our codebase clean and standardized across different operating systems, we enforce formatting using `ruff`:
9
+ * Run `uv run ruff format .` to auto-format your Python code before committing.
10
+ * Run `uv run ruff check .` to check for syntax improvements and linting alerts.
11
+
12
+ ## Strategic Workflow to Build Changes
13
+ 1. **Fork** the repository and create your development branch from `develop`.
14
+ 2. Add your features or bug fixes.
15
+ 3. **Write Tests:** Every command tweak or dependency addition must include an accompanying test inside the `tests/` directory.
16
+ 4. **Run Verification Locally:** Ensure everything functions perfectly by executing:
17
+ ```bash
18
+ uv run pytest
19
+ ```
20
+ 5. Commit your work using clean messages following **Conventional Commits**:
21
+ * `feat: add markdown-to-pdf pipeline support`
22
+ * `fix: prevent color depth degradation on cmyk paths`
23
+
24
+ ## Submitting Pull Requests
25
+ * Open a PR targeting our `develop` branch.
26
+ * Ensure all your pipeline test matrix grids turn **green** inside GitHub Actions.
27
+ * A maintainer will review your logic within a few days. Thank you for making our file utility robust!
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Emmanuel Omoiya
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,139 @@
1
+ Metadata-Version: 2.4
2
+ Name: convashun
3
+ Version: 0.1.0
4
+ Summary: A Ultra-fast, zero-config, cross-platform file conversion utility optimized for developers, documentation teams, and automated robotics data pipelines.
5
+ Author-email: Emmanuel Omoiya <emmanuelomoiya6@gmail.com>
6
+ License: MIT
7
+ License-File: LICENSE
8
+ Classifier: Environment :: Console
9
+ Classifier: License :: OSI Approved :: MIT License
10
+ Classifier: Operating System :: OS Independent
11
+ Classifier: Programming Language :: Python :: 3
12
+ Requires-Python: <3.13,>=3.12
13
+ Requires-Dist: click<8.2.0,>=8.1.7
14
+ Requires-Dist: openpyxl>=3.1.5
15
+ Requires-Dist: pandas>=3.0.3
16
+ Requires-Dist: pillow<11.0.0
17
+ Requires-Dist: pypdf>=6.12.1
18
+ Requires-Dist: python-docx>=1.2.0
19
+ Requires-Dist: reportlab>=4.5.1
20
+ Requires-Dist: rich>=13.7.0
21
+ Requires-Dist: ruff>=0.15.14
22
+ Requires-Dist: typer<0.10.0,>=0.9.0
23
+ Description-Content-Type: text/markdown
24
+
25
+ # convashun 🟢
26
+
27
+ [![Continuous Integration](https://github.com)](https://github.com)
28
+ [![PyPI version](https://shields.io)](https://pypi.org)
29
+ [![License: MIT](https://shields.io)](https://opensource.org)
30
+ [![Supported Platforms](https://shields.io)](https://pypi.org)
31
+
32
+ > ⚔ Ultra-fast, zero-config, cross-platform file conversion utility optimized for developers, documentation teams, and automated robotics data pipelines.
33
+
34
+ Built entirely on top of modern Python type hints (`Typer`), blazingly fast package architecture (`uv`), and robust data utilities. Developed with love for open-source engineering workflows and engineered to seamlessly support the data tracking, documentation, and asset conversion pipelines of communities like **Aurora Robotics**.
35
+
36
+ ---
37
+
38
+ ## šŸ“Š Conversion Matrix
39
+
40
+ `convashun` maps target conversions dynamically using deep binary validation rather than flimsy extension strings.
41
+
42
+
43
+ | Category | Input Formats | Targeted Output Command | Pure Python? | System Dependencies |
44
+ | :--- | :--- | :--- | :--- | :--- |
45
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-png` | Yes | None |
46
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-webp` | Yes | None |
47
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-jpg` | Yes | None |
48
+ | **Spreadsheets** | CSV (Comma Separated Log files) | `convert document to-xlsx` | Yes | None |
49
+ | **Spreadsheets** | XLSX (Multi-sheet spreadsheet layouts)| `convert document xlsx-to-csv` | Yes | None |
50
+ | **Documentation** | PDF Documents | `convert document to-docx` | Yes | None |
51
+ | **Documentation** | PDF Documents | `convert document to-markdown`| Yes | None |
52
+ | **Documentation** | Markdown Markup File (`.md`) | `convert document markdown-to-pdf`| Yes | None |
53
+ | **Office/Academics**| DOCX, DOC, ODT, PPTX | `convert document to-pdf` | No | LibreOffice |
54
+ | **Office/Academics**| PowerPoint Presentations (`.pptx`) | `convert document pptx-to-pdf`| No | LibreOffice |
55
+ | **Office/Academics**| LaTeX Documents (`.tex`) | `convert document tex-to-pdf` | Yes | None |
56
+
57
+ ---
58
+
59
+ ## šŸš€ Quick Start & Installation
60
+
61
+ `convashun` works identically across Windows, macOS, and Linux distributions.
62
+
63
+ ### Method 1: Using `uv` (Highly Recommended)
64
+ Install `convashun` instantly into an isolated, globally accessible environment managed entirely by `uv`:
65
+ ```bash
66
+ uv tool install convashun
67
+ ```
68
+
69
+ ### Method 2: Standard Installation via PyPI
70
+ ```bash
71
+ pip install convashun
72
+ # Or use pipx to isolate system paths cleanly
73
+ pipx install convashun
74
+ ```
75
+
76
+ ---
77
+
78
+ ## šŸ› ļø Usage Examples
79
+
80
+ Once installed, use the global entry command `convert` directly in your terminal interface:
81
+
82
+ ### šŸ–¼ļø Image Operations
83
+ ```bash
84
+ # Convert an image into WebP format with custom compression quality settings
85
+ convert image to-webp input_graphic.png --quality 85
86
+
87
+ # Flatten a complex transparent asset safely into a JPG with a solid white backing
88
+ convert image to-jpg transparent_blueprint.png
89
+
90
+ # Optimize a standard PNG file size automatically without changing resolution parameters
91
+ convert image to-png photographic_capture.jpg --optimize
92
+ ```
93
+
94
+ ### šŸ“„ Document Layouts & Spreadsheet Processing
95
+ ```bash
96
+ # Compile a Markdown README specification file directly into a portable PDF manual
97
+ convert document markdown-to-pdf ARCHITECTURE.md
98
+
99
+ # Extract telemetry or configuration records from an Excel document directly down to a CSV log
100
+ convert document xlsx-to-csv metrics_workbook.xlsx --sheet "TelemetryLogs"
101
+
102
+ # Convert an uneditable PDF report layout back into a semantic Markdown string file
103
+ convert document to-markdown datasheet_report.pdf
104
+ ```
105
+
106
+ ---
107
+
108
+ ## šŸ“¦ System Prerequisites (For Office Documents Only)
109
+
110
+ Commands such as `to-pdf` (for `.docx` and `.pptx`) use automated background processes to render layout definitions precisely. If a command prompts you with a missing dependency, install LibreOffice on your path using your platform package engine:
111
+
112
+ * **macOS:** `brew install libreoffice`
113
+ * **Linux (Ubuntu/Debian):** `sudo apt install libreoffice`
114
+ * **Windows (PowerShell WinGet):** `winget install LibreOffice.LibreOffice`
115
+
116
+ ---
117
+
118
+ ## 🟢 Open Source Contributions
119
+
120
+ We value input from engineering collaborators and the robotics community!
121
+
122
+ To add optimization modules or extend format parsers:
123
+ 1. Review our structured guidelines inside [CONTRIBUTING.md](CONTRIBUTING.md).
124
+ 2. Set up your local sandboxed tracking workspace via `uv`:
125
+ ```bash
126
+ git clone https://github.com
127
+ cd convashun
128
+ uv sync --dev
129
+ ```
130
+ 3. Run the complete automated multi-OS testing validation matrix locally before pushing changes:
131
+ ```bash
132
+ uv run pytest
133
+ ```
134
+
135
+ ---
136
+
137
+ ## šŸ“„ License
138
+
139
+ Distributed safely under the terms of the open-source **MIT License**. Check out [LICENSE](LICENSE) for exact operational data guidelines.
@@ -0,0 +1,115 @@
1
+ # convashun 🟢
2
+
3
+ [![Continuous Integration](https://github.com)](https://github.com)
4
+ [![PyPI version](https://shields.io)](https://pypi.org)
5
+ [![License: MIT](https://shields.io)](https://opensource.org)
6
+ [![Supported Platforms](https://shields.io)](https://pypi.org)
7
+
8
+ > ⚔ Ultra-fast, zero-config, cross-platform file conversion utility optimized for developers, documentation teams, and automated robotics data pipelines.
9
+
10
+ Built entirely on top of modern Python type hints (`Typer`), blazingly fast package architecture (`uv`), and robust data utilities. Developed with love for open-source engineering workflows and engineered to seamlessly support the data tracking, documentation, and asset conversion pipelines of communities like **Aurora Robotics**.
11
+
12
+ ---
13
+
14
+ ## šŸ“Š Conversion Matrix
15
+
16
+ `convashun` maps target conversions dynamically using deep binary validation rather than flimsy extension strings.
17
+
18
+
19
+ | Category | Input Formats | Targeted Output Command | Pure Python? | System Dependencies |
20
+ | :--- | :--- | :--- | :--- | :--- |
21
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-png` | Yes | None |
22
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-webp` | Yes | None |
23
+ | **Images** | JPG, PNG, WEBP, BMP, GIF, TIFF | `convert image to-jpg` | Yes | None |
24
+ | **Spreadsheets** | CSV (Comma Separated Log files) | `convert document to-xlsx` | Yes | None |
25
+ | **Spreadsheets** | XLSX (Multi-sheet spreadsheet layouts)| `convert document xlsx-to-csv` | Yes | None |
26
+ | **Documentation** | PDF Documents | `convert document to-docx` | Yes | None |
27
+ | **Documentation** | PDF Documents | `convert document to-markdown`| Yes | None |
28
+ | **Documentation** | Markdown Markup File (`.md`) | `convert document markdown-to-pdf`| Yes | None |
29
+ | **Office/Academics**| DOCX, DOC, ODT, PPTX | `convert document to-pdf` | No | LibreOffice |
30
+ | **Office/Academics**| PowerPoint Presentations (`.pptx`) | `convert document pptx-to-pdf`| No | LibreOffice |
31
+ | **Office/Academics**| LaTeX Documents (`.tex`) | `convert document tex-to-pdf` | Yes | None |
32
+
33
+ ---
34
+
35
+ ## šŸš€ Quick Start & Installation
36
+
37
+ `convashun` works identically across Windows, macOS, and Linux distributions.
38
+
39
+ ### Method 1: Using `uv` (Highly Recommended)
40
+ Install `convashun` instantly into an isolated, globally accessible environment managed entirely by `uv`:
41
+ ```bash
42
+ uv tool install convashun
43
+ ```
44
+
45
+ ### Method 2: Standard Installation via PyPI
46
+ ```bash
47
+ pip install convashun
48
+ # Or use pipx to isolate system paths cleanly
49
+ pipx install convashun
50
+ ```
51
+
52
+ ---
53
+
54
+ ## šŸ› ļø Usage Examples
55
+
56
+ Once installed, use the global entry command `convert` directly in your terminal interface:
57
+
58
+ ### šŸ–¼ļø Image Operations
59
+ ```bash
60
+ # Convert an image into WebP format with custom compression quality settings
61
+ convert image to-webp input_graphic.png --quality 85
62
+
63
+ # Flatten a complex transparent asset safely into a JPG with a solid white backing
64
+ convert image to-jpg transparent_blueprint.png
65
+
66
+ # Optimize a standard PNG file size automatically without changing resolution parameters
67
+ convert image to-png photographic_capture.jpg --optimize
68
+ ```
69
+
70
+ ### šŸ“„ Document Layouts & Spreadsheet Processing
71
+ ```bash
72
+ # Compile a Markdown README specification file directly into a portable PDF manual
73
+ convert document markdown-to-pdf ARCHITECTURE.md
74
+
75
+ # Extract telemetry or configuration records from an Excel document directly down to a CSV log
76
+ convert document xlsx-to-csv metrics_workbook.xlsx --sheet "TelemetryLogs"
77
+
78
+ # Convert an uneditable PDF report layout back into a semantic Markdown string file
79
+ convert document to-markdown datasheet_report.pdf
80
+ ```
81
+
82
+ ---
83
+
84
+ ## šŸ“¦ System Prerequisites (For Office Documents Only)
85
+
86
+ Commands such as `to-pdf` (for `.docx` and `.pptx`) use automated background processes to render layout definitions precisely. If a command prompts you with a missing dependency, install LibreOffice on your path using your platform package engine:
87
+
88
+ * **macOS:** `brew install libreoffice`
89
+ * **Linux (Ubuntu/Debian):** `sudo apt install libreoffice`
90
+ * **Windows (PowerShell WinGet):** `winget install LibreOffice.LibreOffice`
91
+
92
+ ---
93
+
94
+ ## 🟢 Open Source Contributions
95
+
96
+ We value input from engineering collaborators and the robotics community!
97
+
98
+ To add optimization modules or extend format parsers:
99
+ 1. Review our structured guidelines inside [CONTRIBUTING.md](CONTRIBUTING.md).
100
+ 2. Set up your local sandboxed tracking workspace via `uv`:
101
+ ```bash
102
+ git clone https://github.com
103
+ cd convashun
104
+ uv sync --dev
105
+ ```
106
+ 3. Run the complete automated multi-OS testing validation matrix locally before pushing changes:
107
+ ```bash
108
+ uv run pytest
109
+ ```
110
+
111
+ ---
112
+
113
+ ## šŸ“„ License
114
+
115
+ Distributed safely under the terms of the open-source **MIT License**. Check out [LICENSE](LICENSE) for exact operational data guidelines.
@@ -0,0 +1,44 @@
1
+ [project]
2
+ name = "convashun"
3
+ version = "0.1.0"
4
+ description = "A Ultra-fast, zero-config, cross-platform file conversion utility optimized for developers, documentation teams, and automated robotics data pipelines."
5
+ readme = "README.md"
6
+ # requires-python = ">=3.12"
7
+ requires-python = ">=3.12,<3.13"
8
+ license = { text = "MIT" }
9
+ authors = [
10
+ { name = "Emmanuel Omoiya", email = "emmanuelomoiya6@gmail.com" }
11
+ ]
12
+ classifiers = [
13
+ "Programming Language :: Python :: 3",
14
+ "License :: OSI Approved :: MIT License",
15
+ "Operating System :: OS Independent",
16
+ "Environment :: Console",
17
+ ]
18
+ dependencies = [
19
+ "ruff>=0.15.14",
20
+ "click>=8.1.7,<8.2.0",
21
+ # "typer>=0.12.0",
22
+ "typer>=0.9.0,<0.10.0",
23
+ "rich>=13.7.0", # Added for beautiful cross-platform terminal formatting
24
+ "pillow<11.0.0",
25
+ "pandas>=3.0.3",
26
+ "openpyxl>=3.1.5",
27
+ "pypdf>=6.12.1",
28
+ "python-docx>=1.2.0",
29
+ "reportlab>=4.5.1",
30
+ ]
31
+
32
+ [project.scripts]
33
+ convert = "convashun.cli:app"
34
+
35
+ [build-system]
36
+ requires = ["hatchling"]
37
+ build-backend = "hatchling.build"
38
+
39
+ [dependency-groups]
40
+ dev = [
41
+ "pre-commit>=4.6.0",
42
+ "pytest>=9.0.3",
43
+ "reportlab>=4.5.1",
44
+ ]
@@ -0,0 +1,86 @@
1
+ import subprocess
2
+ import sys
3
+ from pathlib import Path
4
+
5
+ def print_step(msg: str):
6
+ print(f"\n🟢 [SMOKE TEST] {msg}")
7
+
8
+ def print_success(msg: str):
9
+ print(f"āœ… SUCCESS: {msg}")
10
+
11
+ def print_failure(msg: str):
12
+ print(f"āŒ FAILURE: {msg}")
13
+ sys.exit(1)
14
+
15
+ def main():
16
+ print_step("Initializing cross-platform CLI validation pipeline...")
17
+
18
+ # 1. Verify the runtime can execute 'uv' and resolve project status
19
+ try:
20
+ subprocess.run(["uv", "--version"], check=True, stdout=subprocess.DEVNULL)
21
+ print_success("Verified local 'uv' package environment tool binary mapping.")
22
+ except Exception:
23
+ print_failure("'uv' is not installed or missing from system path variables.")
24
+
25
+ # 2. Rebuild local dependency hooks and clear legacy sync tracks
26
+ print_step("Syncing dependency configurations and updating editable build links...")
27
+ try:
28
+ subprocess.run(["uv", "sync"], check=True)
29
+ print_success("Package tracking indexes updated smoothly.")
30
+ except subprocess.CalledProcessError as e:
31
+ print_failure(f"Failed to sync isolated project state environment configurations: {e}")
32
+
33
+ # 3. Test basic CLI entry point invocation
34
+ print_step("Testing global entry script invocation layout ('uv run convert --help')...")
35
+ try:
36
+ result = subprocess.run(
37
+ ["uv", "run", "convert", "--help"],
38
+ capture_output=True,
39
+ text=True,
40
+ check=True
41
+ )
42
+ # Check for your unique project headline to ensure it's executing YOUR tool
43
+ # if "Ultra-fast cross-platform file conversion utility" in result.stdout:
44
+ if "A Ultra-fast, zero-config, cross-platform file conversion utility optimized for developers, documentation teams, and automated robotics data pipelines." in result.stdout:
45
+ print_success("Main CLI command group entry point resolved and answered correctly!")
46
+ else:
47
+ print_failure(f"The 'convert' command answered, but returned an unexpected payload:\n{result.stdout}")
48
+ except subprocess.CalledProcessError as e:
49
+ print_failure(f"CLI invocation crashed or returned a non-zero exit status:\n{e.stderr}")
50
+
51
+ # 4. Test image subcommand navigation track
52
+ print_step("Testing image submodule command mapping ('uv run convert image --help')...")
53
+ try:
54
+ result = subprocess.run(
55
+ ["uv", "run", "convert", "image", "--help"],
56
+ capture_output=True,
57
+ text=True,
58
+ check=True
59
+ )
60
+ if "to-png" in result.stdout and "to-webp" in result.stdout:
61
+ print_success("Image format conversion subcommands registered correctly.")
62
+ else:
63
+ print_failure(f"Image commands routing appears corrupted or incomplete:\n{result.stdout}")
64
+ except subprocess.CalledProcessError as e:
65
+ print_failure(f"Image subcommand group navigation failed:\n{e.stderr}")
66
+
67
+ # 5. Test document subcommand navigation track
68
+ print_step("Testing document submodule command mapping ('uv run convert document --help')...")
69
+ try:
70
+ result = subprocess.run(
71
+ ["uv", "run", "convert", "document", "--help"],
72
+ capture_output=True,
73
+ text=True,
74
+ check=True
75
+ )
76
+ if "to-xlsx" in result.stdout and "to-markdown" in result.stdout:
77
+ print_success("Document and data layout conversion subcommands registered correctly.")
78
+ else:
79
+ print_failure(f"Document commands routing appears corrupted or incomplete:\n{result.stdout}")
80
+ except subprocess.CalledProcessError as e:
81
+ print_failure(f"Document subcommand group navigation failed:\n{e.stderr}")
82
+
83
+ print_step("All system entry routes verified successfully! Your application environment is healthy. šŸŽ‰")
84
+
85
+ if __name__ == "__main__":
86
+ main()
File without changes
@@ -0,0 +1,28 @@
1
+ import typer
2
+ from rich.console import Console
3
+ from convashun import image, document
4
+
5
+ # Create the main Typer application
6
+ app = typer.Typer(
7
+ name="Convashun",
8
+ help="⚔ Ultra-fast cross-platform file conversion utility ⚔",
9
+ add_completion=True,
10
+ )
11
+
12
+ # Initialize rich console for error and status printing
13
+ console = Console()
14
+
15
+ # Attach sub-modules as command groups
16
+ app.add_typer(document.app, name="document", help="Convert document formats (DOCX, PDF, TXT, etc.)")
17
+ app.add_typer(image.app, name="image", help="Convert image formats (PNG, JPG, WEBP, etc.)")
18
+
19
+ @app.callback()
20
+ def main():
21
+ """
22
+ Global settings or configurations can go here.
23
+ This executes before any subcommand.
24
+ """
25
+ pass
26
+
27
+ if __name__ == "__main__":
28
+ app()