Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PSAT CLI: Version Check and Update Prompt for PSAT CLI #815

Closed
3 tasks
gagan0123 opened this issue Aug 23, 2024 · 1 comment
Closed
3 tasks

PSAT CLI: Version Check and Update Prompt for PSAT CLI #815

gagan0123 opened this issue Aug 23, 2024 · 1 comment
Assignees
Milestone

Comments

@gagan0123
Copy link
Collaborator

gagan0123 commented Aug 23, 2024

Feature Request

Description:

Implement a version check mechanism in the PSAT CLI that prompts users to update if they are running an outdated version. Additionally, include the CLI version information in all generated reports.

Motivation:

Users running outdated CLI versions may encounter issues or bugs that have been fixed in newer releases. This leads to unnecessary support requests and a frustrating user experience. Prompting users to update and providing version information in reports will help mitigate this problem.

User Story:

As a PSAT CLI user, I want to be notified if I'm running an outdated version so that I can avoid encountering known issues and get the most accurate results.

Acceptance Criteria:

  • When the PSAT CLI is executed, it checks for the latest version.
  • If a newer version is available, the CLI displays a message to the user, prompting them to update. The message should include clear instructions on how to update (e.g., the npm i -g @google-psat/cli command).
  • The PSAT CLI version used for analysis is included in the metadata of all generated reports (HTML, JSON).

Additional Information:

  • The version check could be performed using NPM's API or by comparing the local version with a version string fetched from a remote source (e.g., package.json file in the GitHub repository for the CLI package).
  • The update prompt message should be clear, concise, and easily noticeable by the user.

Example

You are currently using PSAT CLI version [current_version]. 
A newer version ([latest_version]) is available.

To get the latest features and bug fixes, please update:
npm i -g @google-psat/cli 
@gagan0123
Copy link
Collaborator Author

Released as a part of v0.11.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

No branches or pull requests

3 participants