Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: PSModule/GitHub-Script
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: PSModule/GitHub-Script
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: fix/ensure-single-loaded-module-version
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 5 commits
  • 1 file changed
  • 1 contributor

Commits on Jul 11, 2026

  1. Import the selected GitHub module version and remove other loaded ver…

    …sions
    
    init.ps1 now resolves the exact installed version satisfying the Version input, removes any already-loaded GitHub module versions from the session, and imports the resolved version with -RequiredVersion -Global — so the user script uses the selected version instead of whatever PowerShell would auto-load from PSModulePath.
    MariusStorhaug committed Jul 11, 2026
    Configuration menu
    Copy the full SHA
    3117518 View commit details
    Browse the repository at this point in the history

Commits on Jul 12, 2026

  1. Address review: filter prereleases when not requested and remove all …

    …loaded instances
    
    Per PR review: resolution now excludes prerelease versions when Prerelease is false and adds a stable-wins tie-breaker (so a Prerelease:false run never imports an installed prerelease, and stable wins at equal base version); and 'Get-Module -Name \ -All | Remove-Module' removes every loaded instance before import.
    MariusStorhaug committed Jul 12, 2026
    Configuration menu
    Copy the full SHA
    ba5bfaf View commit details
    Browse the repository at this point in the history
  2. Address review: use Prerelease string, stop on import failure, cleare…

    …r error
    
    Filter/sort on the 'Prerelease' string instead of IsPrerelease; add -ErrorAction Stop to the final Import-Module so a failed load stops the run; and render 'latest' in the throw message when no Version was requested (matching the moduleStatus display).
    MariusStorhaug committed Jul 12, 2026
    Configuration menu
    Copy the full SHA
    e76e997 View commit details
    Browse the repository at this point in the history
  3. Address review: do not treat an installed prerelease as satisfying a …

    …stable request
    
    When Prerelease is false, exclude prereleases from the already-installed check so a machine with only prerelease builds installed still installs a stable version instead of failing resolution.
    MariusStorhaug committed Jul 12, 2026
    Configuration menu
    Copy the full SHA
    a6d0a87 View commit details
    Browse the repository at this point in the history
  4. Address review: keep already-installed status semantics when nothing …

    …matches
    
    Normalize the already-installed set to \ when the (prerelease-filtered) query returns nothing, so the '-not' install guard and the '\ -ne' moduleStatus check both retain their original meaning instead of an empty array reading as 'installed'.
    MariusStorhaug committed Jul 12, 2026
    Configuration menu
    Copy the full SHA
    5ad3beb View commit details
    Browse the repository at this point in the history
Loading