Skip to content

feat: add --version CLI command#17

Merged
janmatzek merged 1 commit into
gooddata:masterfrom
janmatzek:jmat/expose-version-in-cli
Jul 7, 2026
Merged

feat: add --version CLI command#17
janmatzek merged 1 commit into
gooddata:masterfrom
janmatzek:jmat/expose-version-in-cli

Conversation

@janmatzek

@janmatzek janmatzek commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

JIRA: trivial

Summary by CodeRabbit

  • New Features

    • Added a --version option to the CLI so you can quickly check the installed tool version.
    • The CLI now shows a version number when the package is installed, with a clear fallback message if version info isn’t available.
  • Documentation

    • Updated the installation instructions with a command to verify the CLI version after setup.

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: fd771e7f-8ad7-4bae-a1d5-112b803a7cf0

📥 Commits

Reviewing files that changed from the base of the PR and between 4b6a532 and 59cd37b.

📒 Files selected for processing (2)
  • README.md
  • src/gooddata_legacy2cloud/arg_parsing/cli_commands.py

📝 Walkthrough

Walkthrough

This PR adds a --version CLI flag to gooddata-legacy2cloud. It computes __version__ via importlib.metadata.version, falling back to a placeholder string if package metadata is unavailable, wires this into argparse, and documents the new flag in the README.

Changes

CLI Version Flag

Layer / File(s) Summary
Version lookup and CLI flag wiring
src/gooddata_legacy2cloud/arg_parsing/cli_commands.py, README.md
Adds importlib.metadata imports, computes __version__ with a PackageNotFoundError fallback, adds a --version argparse flag, and documents version checking in the README.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Poem

A rabbit hops with version in tow,
"--version" now tells you what you know,
No more guessing which build you run,
One flag, one hop, the job is done! 🐇✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: adding a --version CLI command.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Comment @coderabbitai help to get the list of available commands.

@janmatzek janmatzek merged commit 86e7140 into gooddata:master Jul 7, 2026
2 checks passed
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.

2 participants