Skip to content

Get-NovaProjectInfo -Installed currently returns the installed NovaModuleTools module version #238

Description

@stiwicourage

Problem

Get-NovaProjectInfo -Installed currently returns the installed NovaModuleTools module version, while the CLI already uses a different and clearer split:

  • nova version --installed returns the installed version of the current project module
  • nova --version returns the installed NovaModuleTools version

This makes the PowerShell cmdlet surface inconsistent with the CLI surface and gives -Installed the wrong meaning on Get-NovaProjectInfo.

Goal

Align the PowerShell cmdlet behavior with the existing CLI semantics without adding a new public cmdlet.

Proposed scope

  • Change Get-NovaProjectInfo -Installed to return the installed current-project module version from the local module path.
  • Add Get-NovaProjectInfo -InstalledNovaVersion to return the installed NovaModuleTools module version.
  • Keep CLI behavior unchanged.
  • Update tests, help, README, changelog, release notes, and update-flow guidance to match.

Out of scope

  • No changes to % nova version, % nova --version, or other CLI routes.
  • No new public Get-NovaVersion cmdlet.
  • No broader redesign of version formatting.

Implementation notes

  • Reuse Get-NovaInstalledProjectVersion for the -Installed path.
  • Keep Get-NovaProjectInfo thin and delegating.
  • If needed, extract a small private helper for the installed NovaModuleTools version path rather than keeping mixed semantics inline.
  • Update the self-update next-step hint from Get-NovaProjectInfo -Installed to Get-NovaProjectInfo -InstalledNovaVersion.

Acceptance criteria

  • Get-NovaProjectInfo -Version still returns the version from project.json.
  • Get-NovaProjectInfo -Installed returns the installed version of the current project module.
  • Get-NovaProjectInfo -Installed surfaces the existing actionable “local module install not found” error when the project module is not installed locally.
  • Get-NovaProjectInfo -InstalledNovaVersion returns the installed NovaModuleTools module name/version string.
  • % nova version, % nova version --installed, and % nova --version remain unchanged.
  • Public/help tests are updated and passing.
  • Architecture guardrail expectations are updated if helper usage changes.
  • Get-NovaProjectInfo help and README clearly document the three version-related modes.
  • CHANGELOG.md and RELEASE_NOTE.md reflect the PowerShell behavior change.

Validation

pwsh -NoLogo -NoProfile -File ./run.ps1                                                                                                                     
Test-NovaBuild                                                                                                                                              

Likely files

  • src/public/GetNovaProjectInfo.ps1
  • src/private/release/GetNovaInstalledProjectVersion.ps1
  • any new/extracted private helper used by Get-NovaProjectInfo
  • tests/public/GetNovaProjectInfo.Tests.ps1
  • tests/public/GetNovaProjectInfo.TestSupport.ps1
  • tests/ArchitectureGuardrails.Tests.ps1
  • src/private/update/InvokeNovaModuleSelfUpdateWorkflow.ps1
  • tests/private/update/InvokeNovaModuleSelfUpdateWorkflow.Tests.ps1
  • docs/NovaModuleTools/en-US/Get-NovaProjectInfo.md
  • docs/NovaModuleTools/en-US/Update-NovaModuleTools.md
  • README.md
  • CHANGELOG.md
  • RELEASE_NOTE.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions