docs: ✏️ Update documentation for GPOZaurr module

- Revised `Set-GPOZaurrOwner.md` to enhance clarity and detail for parameters and examples.
- Updated `Set-GPOZaurrStatus.md` with a new online version link and improved structure.
- Refined `Skip-GroupPolicy.md` to clarify usage within script blocks and added examples.
- Adjusted `GPOZaurr.psd1` for version updates and improved module dependencies.
- Enhanced `GPOZaurr.psm1` for better error handling during function imports.
- Modified `Invoke-GPOZaurrSupport.ps1` examples to use `Join-Path` for path construction.
This commit is contained in:
Przemysław Kłys
2026-05-19 18:47:50 +02:00
parent b672783a3f
commit f7bdaca724
66 changed files with 9573 additions and 11029 deletions
@@ -1,41 +1,4 @@
[CmdletBinding()]
param(
[switch]$SkipPublish
)
try {
Clear-Host
} catch {
Write-Verbose "Skipping Clear-Host because the current host is non-interactive."
}
function Import-LocalPSPublishModule {
$candidateRoots = @()
if ($env:POWERFORGE_ROOT) {
$candidateRoots += $env:POWERFORGE_ROOT
}
$candidateRoots += [System.IO.Path]::GetFullPath((Join-Path $PSScriptRoot '..\..\PSPublishModule'))
foreach ($root in $candidateRoots | Select-Object -Unique) {
if ([string]::IsNullOrWhiteSpace($root)) {
continue
}
$manifestPath = Join-Path $root 'Module\PSPublishModule.psd1'
if (Test-Path -LiteralPath $manifestPath -PathType Leaf) {
Import-Module $manifestPath -Force -ErrorAction Stop
return
}
}
Import-Module PSPublishModule -Force -ErrorAction Stop
}
Import-LocalPSPublishModule
Invoke-ModuleBuild -ModuleName 'GPOZaurr' {
Build-Module -ModuleName 'GPOZaurr' {
# Usual defaults as per standard module
$Manifest = @{
# Version number of this module.
@@ -63,17 +26,9 @@ Invoke-ModuleBuild -ModuleName 'GPOZaurr' {
New-ConfigurationManifest @Manifest
New-ConfigurationModule -Type RequiredModule -Name 'PSWriteColor', 'PSSharedGoods', 'ADEssentials' -Guid Auto -Version Latest
New-ConfigurationModule -Type RequiredModule -Name "PSWriteHTML" -Guid Auto -Version "1.27.0"
New-ConfigurationModule -Type RequiredModule -Name "PSWriteHTML" -Guid Auto -Version Latest
#New-ConfigurationModule -Type ExternalModule -Name 'Microsoft.PowerShell.Utility', 'Microsoft.PowerShell.Management','Microsoft.PowerShell.Security'
New-ConfigurationModule -Type ApprovedModule -Name 'PSSharedGoods', 'PSWriteColor', 'Connectimo', 'PSUnifi', 'PSWebToolbox', 'PSMyPassword', 'ADEssentials'
New-ConfigurationModule -Type ExternalModule -Name @(
"CimCmdlets"
'Microsoft.PowerShell.Management'
'Microsoft.PowerShell.Utility'
'Microsoft.PowerShell.Security'
)
New-ConfigurationModuleSkip -IgnoreModuleName @(
# this are builtin into PowerShell, so not critical
'powershellget'
@@ -243,7 +198,7 @@ Invoke-ModuleBuild -ModuleName 'GPOZaurr' {
# when creating PSD1 use special style without comments and with only required parameters
New-ConfigurationFormat -ApplyTo 'DefaultPSD1', 'OnMergePSD1' -PSD1Style 'Minimal'
# configuration for documentation, at the same time it enables documentation processing
New-ConfigurationDocumentation -Enable:$true -StartClean -UpdateWhenNew -SyncExternalHelpToProjectRoot -PathReadme 'Docs\Readme.md' -Path 'Docs'
New-ConfigurationDocumentation -Enable:$true -StartClean -UpdateWhenNew -SyncExternalHelpToProjectRoot -PathReadme 'Docs\Readme.md' -Path 'Docs'
#New-ConfigurationImportModule -ImportSelf
@@ -254,9 +209,9 @@ Invoke-ModuleBuild -ModuleName 'GPOZaurr' {
New-ConfigurationArtefact -Type Unpacked -Enable -Path "$PSScriptRoot\..\Artefacts\Unpacked" -AddRequiredModules
New-ConfigurationArtefact -Type Packed -Enable -Path "$PSScriptRoot\..\Artefacts\Packed" -ArtefactName '<ModuleName>.v<ModuleVersion>.zip' -AddRequiredModules
# options for publishing to github/psgallery
if (-not $SkipPublish) {
New-ConfigurationPublish -Type PowerShellGallery -FilePath 'C:\Support\Important\PowerShellGalleryAPI.txt' -Enabled:$true
New-ConfigurationPublish -Type GitHub -FilePath 'C:\Support\Important\GitHubAPI.txt' -UserName 'EvotecIT' -Enabled:$true
}
} -ExitCode
# options for publishing to github/psgallery
if (-not $SkipPublish) {
#New-ConfigurationPublish -Type PowerShellGallery -FilePath 'C:\Support\Important\PowerShellGalleryAPI.txt' -Enabled:$true
# New-ConfigurationPublish -Type GitHub -FilePath 'C:\Support\Important\GitHubAPI.txt' -UserName 'EvotecIT' -Enabled:$true -GenerateReleaseNotes
}
} -ExitCode