Skip to content

feat: add CLI#15

Merged
edmondchuc merged 5 commits into
mainfrom
edmond/rename
Jan 25, 2026
Merged

feat: add CLI#15
edmondchuc merged 5 commits into
mainfrom
edmond/rename

Conversation

@edmondchuc

Copy link
Copy Markdown
Contributor

No description provided.

- Add typer as optional dependency under [cli] extra
- Add 'sparql format <path>' command to format files in-place
- Add 'sparql check <path>' command to verify files are formatted
- Support both single files and directories (.rq, .sparql extensions)
- Handle SparqlSyntaxError with user-friendly messages
- Add comprehensive tests for CLI commands
- Add 'version' subcommand using importlib.metadata to read version from pyproject.toml
- Enable both -h and --help via context_settings
- Update tests to use 'format' subcommand explicitly
- Add tests for -h flag and version command
- Add 'install' task to Taskfile.yml using uv sync --all-extras
- Add arduino/setup-task@v2 step to all GitHub workflows
- Replace 'uv sync' with 'task install' in ci, release, and pypi workflows

This ensures optional dependencies (like typer) are installed in CI.
- Replace separate ruff/mypy steps with 'task code:check' in CI
- Add main.py to code and code:check tasks in Taskfile.yml
- Ignore E501 for main.py (contains SPARQL query strings)
@edmondchuc
edmondchuc merged commit 1ae2f34 into main Jan 25, 2026
6 checks passed
@edmondchuc
edmondchuc deleted the edmond/rename branch January 25, 2026 12:56
@edmondchuc edmondchuc mentioned this pull request Jan 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant