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

Displays build version of input ISO #3015

Merged
merged 1 commit into from
Nov 7, 2024

Conversation

Warrentheo
Copy link
Contributor

Type of Change
Minor update (Console output addition)
Description
This PR adds a Write-Host statement to display the Windows Image version in the console. The change outputs the retrieved image version ($imgVersion) to provide visibility into the version details directly within the script execution output.

Example output:
The Windows Image Build Version is: [version number]

This modification is particularly useful for users who need to confirm the version of the Windows Image being processed.

Testing
Testing involved running the script to ensure that the Write-Host statement correctly displays the image version without causing any errors or affecting existing functionality.

Impact
This change has no impact on performance, dependencies, or behavior beyond adding a simple console output. It provides helpful feedback for users reviewing the image details in the script.

Issue related to PR
N/A

Additional Information
N/A

Checklist
My code adheres to the coding and style guidelines of the project.
I have performed a self-review of my own code.
I have commented my code, particularly in hard-to-understand areas.
I have made corresponding changes to the documentation.
My changes generate no errors/warnings/merge conflicts.

@@ -76,6 +76,7 @@ public class PowerManagement {
}

$imgVersion = (Get-WindowsImage -ImagePath $mountDir\sources\install.wim -Index $index).Version
Write-Host "The Windows Image Build Version is: $imgVersion"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Write-Host "The Windows Image Build Version is: $imgVersion"
Write-Host "Version of selected image: $imgVersion"

While this works correctly, I would rephrase this a bit

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do recommend having the word build in there somewhere as that is technically what it is, and something to make it clear that windows version 10.x includes windows 11

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. It is a good change, regardless

Copy link
Contributor Author

@Warrentheo Warrentheo Nov 7, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do agree it could probably do with a rewording from my phrasing, best one would be something that translates build numbers into actual version numbers, build such and such is Win11 23H2 for instance, but then you have to maintain that for future changes, so not ideal...

@ChrisTitusTech ChrisTitusTech merged commit bbc18b2 into ChrisTitusTech:main Nov 7, 2024
1 check 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.

3 participants