├── .github └── FUNDING.yml ├── .gitignore ├── Build └── Manage-PSSharedGoods.ps1 ├── CHANGELOG.MD ├── Docs ├── Add-PropertyToList.md ├── Add-ToArray.md ├── Add-ToArrayAdvanced.md ├── Add-ToHashTable.md ├── Add-WinADUserGroups.md ├── Compare-ObjectProperties.md ├── Compare-ObjectsAdvanced.md ├── Connect-WinAzure.md ├── Connect-WinAzureAD.md ├── Connect-WinExchange.md ├── Connect-WinSecurityCompliance.md ├── Connect-WinService.md ├── Connect-WinSharePoint.md ├── Connect-WinSkype.md ├── Connect-WinTeams.md ├── Convert-BinaryToHex.md ├── Convert-BinaryToString.md ├── Convert-Color.md ├── Convert-ExchangeEmail.md ├── Convert-ExchangeItems.md ├── Convert-ExchangeRecipientDetails.md ├── Convert-ExchangeSize.md ├── Convert-HexToBinary.md ├── Convert-KeyToKeyValue.md ├── Convert-Office365License.md ├── Convert-Size.md ├── Convert-TimeToDays.md ├── Convert-ToDateTime.md ├── Convert-ToTimeSpan.md ├── Convert-TwoArraysIntoOne.md ├── Convert-UAC.md ├── ConvertFrom-Color.md ├── ConvertFrom-ErrorRecord.md ├── ConvertFrom-OperationType.md ├── ConvertFrom-SID.md ├── ConvertFrom-X500Address.md ├── ConvertTo-ImmutableID.md ├── Disconnect-WinAzure.md ├── Disconnect-WinAzureAD.md ├── Disconnect-WinExchange.md ├── Disconnect-WinSecurityCompliance.md ├── Disconnect-WinService.md ├── Disconnect-WinSkype.md ├── Disconnect-WinTeams.md ├── Find-ADConnectServer.md ├── Find-DatesCurrentDayMinusDayX.md ├── Find-DatesCurrentDayMinuxDaysX.md ├── Find-DatesCurrentHour.md ├── Find-DatesDayPrevious.md ├── Find-DatesDayToday.md ├── Find-DatesMonthCurrent.md ├── Find-DatesMonthPast.md ├── Find-DatesPastHour.md ├── Find-DatesPastWeek.md ├── Find-DatesQuarterCurrent.md ├── Find-DatesQuarterLast.md ├── Find-ExchangeServer.md ├── Find-HyperVServer.md ├── Find-MyProgramData.md ├── Find-ServerTypes.md ├── Find-TypesNeeded.md ├── Find-UsersProxyAddressesStatus.md ├── Format-AddSpaceToSentence.md ├── Format-FirstXChars.md ├── Format-PSTable.md ├── Format-Stream.md ├── Format-ToTitleCase.md ├── Format-TransposeTable.md ├── Format-Verbose.md ├── Format-View.md ├── Get-CimData.md ├── Get-CommandInfo.md ├── Get-ComputerApplications.md ├── Get-ComputerBios.md ├── Get-ComputerCPU.md ├── Get-ComputerCulture.md ├── Get-ComputerDisk.md ├── Get-ComputerDiskLogical.md ├── Get-ComputerMissingDrivers.md ├── Get-ComputerNetwork.md ├── Get-ComputerOemInformation.md ├── Get-ComputerOperatingSystem.md ├── Get-ComputerServices.md ├── Get-ComputerStartup.md ├── Get-ComputerSystem.md ├── Get-ComputerWindowsFeatures.md ├── Get-ComputerWindowsUpdates.md ├── Get-FileInformation.md ├── Get-FileName.md ├── Get-FileSize.md ├── Get-FilesInFolder.md ├── Get-HTML.md ├── Get-HashMaxValue.md ├── Get-IPAddressInformation.md ├── Get-InstalledApplication.md ├── Get-Logger.md ├── Get-MimeType.md ├── Get-ModulesAvailability.md ├── Get-MyIpAddress.md ├── Get-ObjectCount.md ├── Get-ObjectData.md ├── Get-ObjectEnumValues.md ├── Get-ObjectKeys.md ├── Get-ObjectProperties.md ├── Get-ObjectPropertiesAdvanced.md ├── Get-ObjectTitles.md ├── Get-ObjectType.md ├── Get-PathSeparator.md ├── Get-PathTemporary.md ├── Get-RandomCharacters.md ├── Get-RandomPassword.md ├── Get-RandomStringName.md ├── Get-ServerRoles.md ├── Get-SqlQueryColumnInformation.md ├── Get-TimeSynchronization.md ├── Get-TimeZoneAdvanced.md ├── Get-TimeZoneLegacy.md ├── Get-Types.md ├── Get-WinADForestControllers.md ├── Get-WinADForestOptions.md ├── Get-WinADOrganizationalUnitData.md ├── Get-WinADOrganizationalUnitFromDN.md ├── Get-WinADUserSnapshot.md ├── Get-WinADUsersByDN.md ├── Get-WinADUsersByOU.md ├── Install-ApplicationClickOnce.md ├── Install-WinConnectity.md ├── Merge-Array.md ├── Merge-Objects.md ├── New-ArrayList.md ├── New-GenericList.md ├── New-Runspace.md ├── New-SqlQuery.md ├── New-SqlQueryAlterTable.md ├── New-SqlQueryCreateTable.md ├── New-SqlTableMapping.md ├── New-UserAdd.md ├── Readme.md ├── Remove-DuplicateObjects.md ├── Remove-FilePermission.md ├── Remove-FromArray.md ├── Remove-ObjectsExistingInTarget.md ├── Remove-WhiteSpace.md ├── Remove-WinADUserGroups.md ├── Rename-LatinCharacters.md ├── Rename-UserValuesFromHash.md ├── Request-Credentials.md ├── Save-XML.md ├── Search-Command.md ├── Send-Email.md ├── Send-SqlInsert.md ├── Set-DnsServerIpAddress.md ├── Set-EmailBody.md ├── Set-EmailBodyPreparedTable.md ├── Set-EmailBodyReplacement.md ├── Set-EmailBodyReplacementTable.md ├── Set-EmailFormatting.md ├── Set-EmailHead.md ├── Set-EmailReportBranding.md ├── Set-EmailWordReplacements.md ├── Set-EmailWordReplacementsHash.md ├── Set-FileInheritance.md ├── Set-FilePermission.md ├── Set-PasswordRemotely.md ├── Set-ServiceRecovery.md ├── Set-SpecUser.md ├── Set-TimeSynchronization.md ├── Set-WinADGroupSynchronization.md ├── Set-WinADUserFields.md ├── Set-WinADUserSettingGAL.md ├── Set-WinADUserStatus.md ├── Set-WinAzureADUserField.md ├── Set-WinAzureADUserLicense.md ├── Set-WinAzureADUserStatus.md ├── Set-XML.md ├── Show-Array.md ├── Show-DataInVerbose.md ├── Show-TableVisualization.md ├── Split-Array.md ├── Split-ArrayEvery.md ├── Start-MyProgram.md ├── Start-Runspace.md ├── Start-TimeLog.md ├── Stop-Runspace.md ├── Stop-TimeLog.md ├── Test-AvailabilityCommands.md ├── Test-ComputerAvailability.md ├── Test-ComputerPort.md ├── Test-ConfigurationCredentials.md ├── Test-ForestConnectivity.md ├── Test-InstalledApplication.md ├── Test-Key.md ├── Test-ModuleAvailability.md ├── Test-WinRM.md └── Uninstall-ApplicationClickOnce.md ├── Enums └── RGBColors.ps1 ├── Examples ├── CompareObjects.ps1 ├── CompareObjects2.ps1 ├── Computer-Time.ps1 ├── ComputerDetails.ps1 ├── ComputerDetails01.ps1 ├── Connectivity.ps1 ├── ConvertCountry.ps1 ├── ConvertFlatObject.ps1 ├── ConvertFlatObject02.ps1 ├── ConvertIdentity1.ps1 ├── ConvertIdentity2.ps1 ├── ConvertIdentity3.ps1 ├── ConvertIdentity4.ps1 ├── ConvertIdentity5.ps1 ├── ConvertIdentity6.ps1 ├── ConvertOffice365Licenses.ps1 ├── ConvertTo-JSON │ ├── ConvertToJson01.ps1 │ ├── ConvertToJson02.ps1 │ ├── ConvertToJson03.ps1 │ ├── ConvertToJson04.ps1 │ ├── ConvertToJson05.ps1 │ ├── ConvertToJson06.ps1 │ ├── ConvertToJson07.ps1 │ ├── ConvertToJson08.ps1 │ ├── ConvertToJson09.ps1 │ ├── ConvertToJson10.ps1 │ ├── ConvertToJson11.ps1 │ └── ConvertToJson12.ps1 ├── Converts.ps1 ├── CopyDictionary.ps1 ├── CopyDictionary1.ps1 ├── Example-01-FileMetaData.ps1 ├── Example-02-OperatingSystemTranslation.ps1 ├── File-Permissions.ps1 ├── File-Permissions01.ps1 ├── File-Permissions02.ps1 ├── Format-Stream1.ps1 ├── Format-Stream2.ps1 ├── Format-Stream3.ps1 ├── FunTest.ps1 ├── FunTest0.ps1 ├── FunTest2.ps1 ├── FunTest3.ps1 ├── Get-ComputerInformation.ps1 ├── GetDomainControllers.ps1 ├── GetDotNet.ps1 ├── OperatingSystemsVersions.ps1 ├── Permissions.ps1 ├── RegistryGet.ps1 ├── RegistryGetDefault.ps1 ├── RegistryNew.ps1 ├── RegistryRemove.ps1 ├── RegistrySet.ps1 ├── RemoveFiles.ps1 ├── Services.ps1 ├── SpeedTest.ps1 ├── TestIP.ps1 └── TransposeTable.ps1 ├── License ├── PSSharedGoods.AzurePipelines.Linux.yml ├── PSSharedGoods.AzurePipelines.macOs.yml ├── PSSharedGoods.AzurePipelines.yml ├── PSSharedGoods.Tests.ps1 ├── PSSharedGoods.psd1 ├── PSSharedGoods.psm1 ├── Private ├── Convert-BinaryToIP.ps1 ├── Convert-GenericRightsToFileSystemRights.ps1 ├── Convert-IPToBinary.ps1 ├── ConvertFrom-HTML.ps1 ├── ConvertTo-HkeyUser.ps1 ├── ConvertTo-StringByType.ps1 ├── Deprecated │ ├── ActiveDirectory │ │ ├── Add-WinADUserGroups.ps1 │ │ ├── Find-ADConnectServer.ps1 │ │ ├── Find-ExchangeServer.ps1 │ │ ├── Find-HyperVServer.ps1 │ │ ├── Find-ServerTypes.ps1 │ │ ├── Find-UserProxyAddressesStatus.ps1 │ │ ├── Get-ADAdministrativeGroups.ps1 │ │ ├── Get-WinADOrganizationalUnitData.ps1 │ │ ├── Get-WinADOrganizationalUnitFromDN.ps1 │ │ ├── Get-WinADUserSnapshot.ps1 │ │ ├── Get-WinADUsersByOU.ps1 │ │ ├── Get-WinADusersByDN.ps1 │ │ ├── Remove-WinADUserGroups.ps1 │ │ ├── Set-WinADGroupSynchronization.ps1 │ │ ├── Set-WinADUserFields.ps1 │ │ ├── Set-WinADUserSettingGAL.ps1 │ │ └── Set-WinADUserStatus.ps1 │ ├── Dates │ │ ├── Find-DatesCurrentDayMinusDayX.ps1 │ │ ├── Find-DatesCurrentDayMinuxDaysX.ps1 │ │ ├── Find-DatesCurrentHour.ps1 │ │ ├── Find-DatesDayPrevious.ps1 │ │ ├── Find-DatesDayToday.ps1 │ │ ├── Find-DatesMonthCurrent.ps1 │ │ ├── Find-DatesMonthPast.ps1 │ │ ├── Find-DatesPastHour.ps1 │ │ ├── Find-DatesPastWeek.ps1 │ │ ├── Find-DatesQuarterCurrent.ps1 │ │ └── Find-DatesQuarterLast.ps1 │ ├── Email │ │ ├── Get-HTML.ps1 │ │ ├── Send-Email.ps1 │ │ ├── Set-EmailBody.ps1 │ │ ├── Set-EmailBodyPreparedTable.ps1 │ │ ├── Set-EmailBodyReplacement.ps1 │ │ ├── Set-EmailBodyTableReplacement.ps1 │ │ ├── Set-EmailFormatting.ps1 │ │ ├── Set-EmailHead.ps1 │ │ ├── Set-EmailReportBranding.ps1 │ │ ├── Set-EmailWordReplacements.ps1 │ │ └── Set-EmailWordReplacementsHash.ps1 │ ├── Logging │ │ └── Get-Logger.ps1 │ ├── Objects │ │ ├── Add-ToArray.ps1 │ │ ├── Add-ToArrayAdvanced.ps1 │ │ ├── Add-ToHashTable.ps1 │ │ ├── Get-HashMaxValue.ps1 │ │ ├── Get-ObjectCount.ps1 │ │ ├── Get-ObjectData.ps1 │ │ ├── Get-ObjectEnumValues.ps1 │ │ ├── Get-ObjectKeys.ps1 │ │ ├── Get-ObjectProperties.ps1 │ │ ├── Get-ObjectPropertiesAdvanced.ps1 │ │ ├── Get-ObjectTitles.ps1 │ │ ├── Get-ObjectType.ps1 │ │ ├── New-ArrayList.ps1 │ │ ├── New-GenericList.ps1 │ │ └── Remove-FromArray.ps1 │ └── SQL │ │ ├── Get-SqlQueryColumnInformation.ps1 │ │ ├── New-SqlQuery.ps1 │ │ ├── New-SqlQueryAlterTable.ps1 │ │ ├── New-SqlQueryCreateTable.ps1 │ │ ├── New-SqlTableMapping.ps1 │ │ └── Send-SqlInsert.ps1 ├── Get-ComputerSMBInfo.ps1 ├── Get-ComputerSplit.ps1 ├── Get-IPRange.ps1 ├── Get-LocalComputerSid.ps1 ├── Get-OfflineRegistryProfilesPath.ps1 ├── Get-PSConvertSpecialRegistry.ps1 ├── Get-PSSubRegistry.ps1 ├── Get-PSSubRegistryComplete.ps1 ├── Get-PSSubRegistryTranslated.ps1 ├── Get-PrivateRegistryTranslated.ps1 ├── Mount-AllRegistryPath.ps1 ├── Mount-DefaultRegistryPath.ps1 ├── New-PrivateRegistry.ps1 ├── Parameters │ ├── Script.RGBColors.ps1 │ └── Script.RegistryDictionaries.ps1 ├── Remove-ChildItems.ps1 ├── Remove-PrivateRegistry.ps1 ├── Request-Credential.ps1 ├── Resolve-PrivateRegistry.ps1 ├── Set-PrivateRegistry.ps1 ├── Test-IPIsInNetwork.ps1 └── Unregister-MountedRegistry.ps1 ├── Public ├── ActiveDirectory │ ├── Convert-ADGuidToSchema.ps1 │ ├── Convert-ADSchemaToGuid.ps1 │ ├── Get-ADEncryptionTypes.ps1 │ ├── Get-ADTrustAttributes.ps1 │ ├── Get-WinADDSAGuid.ps1 │ ├── Get-WinADForestControllers.ps1 │ ├── Get-WinADForestDetails.ps1 │ └── Get-WinADForestOptions.ps1 ├── Computers │ ├── Get-CimData.ps1 │ ├── Get-Computer.ps1 │ ├── Get-ComputerApplication.ps1 │ ├── Get-ComputerBios.ps1 │ ├── Get-ComputerCPU.ps1 │ ├── Get-ComputerCulture.ps1 │ ├── Get-ComputerDevice.ps1 │ ├── Get-ComputerDisk.ps1 │ ├── Get-ComputerDiskLogical.ps1 │ ├── Get-ComputerFirewall.ps1 │ ├── Get-ComputerInstalledUpdates.ps1 │ ├── Get-ComputerMemory.ps1 │ ├── Get-ComputerMissingDrivers.ps1 │ ├── Get-ComputerNetFramework.ps1 │ ├── Get-ComputerNetwork.ps1 │ ├── Get-ComputerOEMInformation.ps1 │ ├── Get-ComputerOperatingSystem.ps1 │ ├── Get-ComputerPorts.ps1 │ ├── Get-ComputerRAM.ps1 │ ├── Get-ComputerRDP.ps1 │ ├── Get-ComputerRoles.ps1 │ ├── Get-ComputerSMB.ps1 │ ├── Get-ComputerSMBShare.ps1 │ ├── Get-ComputerSMBShareList.ps1 │ ├── Get-ComputerSMBSharePermissions.ps1 │ ├── Get-ComputerServices.ps1 │ ├── Get-ComputerStartup.ps1 │ ├── Get-ComputerSystem.ps1 │ ├── Get-ComputerTask.ps1 │ ├── Get-ComputerTime.ps1 │ ├── Get-ComputerTimeNtp.ps1 │ ├── Get-ComputerWindowsFeatures.ps1 │ ├── Get-ComputerWindowsUpdates.ps1 │ └── Get-OperatingSystem.ps1 ├── Connectivity │ ├── Get-IPAddressInformation.ps1 │ ├── Get-MyIpAddress.ps1 │ └── Set-PasswordRemotely.ps1 ├── Converts │ ├── Convert-BinaryToHex.ps1 │ ├── Convert-BinaryToString.ps1 │ ├── Convert-Color.ps1 │ ├── Convert-CountryCodeToCountry.ps1 │ ├── Convert-CountryToContinent.ps1 │ ├── Convert-CountryToCountryCode.ps1 │ ├── Convert-DomainFqdnToNetBIOS.ps1 │ ├── Convert-DomainToSid.ps1 │ ├── Convert-ExchangeEmail.ps1 │ ├── Convert-ExchangeItems.ps1 │ ├── Convert-ExchangeRecipient.ps1 │ ├── Convert-ExchangeSize.ps1 │ ├── Convert-FromColor.ps1 │ ├── Convert-HexToBinary.ps1 │ ├── Convert-IPAddressToPTR.ps1 │ ├── Convert-Identity.ps1 │ ├── Convert-KeyToValue.ps1 │ ├── Convert-Office365License.ps1 │ ├── Convert-Size.ps1 │ ├── Convert-TimeToDays.ps1 │ ├── Convert-ToDateTime.ps1 │ ├── Convert-ToTimeSpan.ps1 │ ├── Convert-TwoArraysIntoOne.ps1 │ ├── Convert-UAC.ps1 │ ├── Convert-UserAccountControl.ps1 │ ├── ConvertFrom-DistinguishedName.ps1 │ ├── ConvertFrom-ErrorRecord.ps1 │ ├── ConvertFrom-LanguageCode.ps1 │ ├── ConvertFrom-NetbiosName.ps1 │ ├── ConvertFrom-ObjectToString.ps1 │ ├── ConvertFrom-OperationType.ps1 │ ├── ConvertFrom-SID.ps1 │ ├── ConvertFrom-ScriptBlock.ps1 │ ├── ConvertFrom-X500Address.ps1 │ ├── ConvertTo-DistinguishedName.ps1 │ ├── ConvertTo-FlatHashTable.ps1 │ ├── ConvertTo-FlatObject.ps1 │ ├── ConvertTo-Identity.ps1 │ ├── ConvertTo-ImmutableID.ps1 │ ├── ConvertTo-JsonLiteral.ps1 │ ├── ConvertTo-NormalizedString.ps1 │ ├── ConvertTo-OperatingSystem.ps1 │ ├── ConvertTo-OrderedDictionary.ps1 │ ├── ConvertTo-PrettyObject.ps1 │ └── ConvertTo-SID.ps1 ├── DNS │ └── Set-DNSServerIPAddress.ps1 ├── FilesFolders │ ├── Get-FileEncoding.ps1 │ ├── Get-FileInformation.ps1 │ ├── Get-FileMetaData.ps1 │ ├── Get-FileName.ps1 │ ├── Get-FileOwner.ps1 │ ├── Get-FilePermission.ps1 │ ├── Get-FileSize.ps1 │ ├── Get-FilesInFolder.ps1 │ ├── Get-PathSeparator.ps1 │ ├── Get-PathTemporary.ps1 │ ├── Get-TemporaryDirectory.ps1 │ ├── Remove-FileItem.ps1 │ ├── Remove-FilePermission.ps1 │ ├── Set-FileInheritance.ps1 │ ├── Set-FileOwner.ps1 │ └── Set-FilePermissions.ps1 ├── Get-ProtocolDefaults.ps1 ├── GitHub │ ├── Get-GitHubLatestRelease.ps1 │ └── Get-GitHubVersion.ps1 ├── IP │ └── Get-IPAddressRangeInformation.ps1 ├── Logging │ ├── Set-LoggingCapabilities.ps1 │ └── Set-ReportingCapabilities.ps1 ├── Objects │ ├── Clean-DataInformation.ps1 │ ├── Compare-MultipleObjects.ps1 │ ├── Compare-ObjectAdvanced.ps1 │ ├── Compare-ObjectProperties.ps1 │ ├── Copy-Dictionary.ps1 │ ├── Copy-DictionaryManual.ps1 │ ├── Format-Dictionary.ps1 │ ├── Format-FirstXChars.ps1 │ ├── Format-PSTable.ps1 │ ├── Format-Stream.ps1 │ ├── Format-StringToSentence.ps1 │ ├── Format-ToTitleCase.ps1 │ ├── Format-TransposeTable.ps1 │ ├── Format-View.ps1 │ ├── Get-Colors.ps1 │ ├── Get-DataInformation.ps1 │ ├── Get-MimeType.ps1 │ ├── Get-Types.ps1 │ ├── Join-Uri.ps1 │ ├── Join-UriQuery.ps1 │ ├── Merge-Array.ps1 │ ├── Merge-Objects.ps1 │ ├── Remove-DuplicateObjects.ps1 │ ├── Remove-EmptyValue.ps1 │ ├── Remove-ObjectsExistingInTarget.ps1 │ ├── Remove-WhiteSpace.ps1 │ ├── Rename-LatinCharacters.ps1 │ ├── Rename-UserValuesFromHash.ps1 │ ├── Select-Properties.ps1 │ ├── Split-Array.ps1 │ └── Test-IsDistinguishedName.ps1 ├── Programs │ ├── Find-MyProgramData.ps1 │ ├── Initialize-ModulePortable.ps1 │ ├── Invoke-CommandCustom.ps1 │ ├── Start-InternalFunction.ps1 │ └── Start-MyProgram.ps1 ├── Random │ ├── Get-RandomCharacters.ps1 │ ├── Get-RandomFileName.ps1 │ ├── Get-RandomPassword.ps1 │ └── Get-RandomStringName.ps1 ├── Registry │ ├── Dismount-PSRegistryPath.ps1 │ ├── Get-PSRegistry.ps1 │ ├── Mount-PSRegistryPath.ps1 │ ├── New-PSRegistry.ps1 │ ├── Remove-PSRegistry.ps1 │ ├── Set-PSRegistry.ps1 │ └── Test-PSRegistry.ps1 ├── Runspaces │ ├── New-Runspace.ps1 │ ├── Start-Runspace.ps1 │ └── Stop-Runspace.ps1 ├── Services │ ├── Get-PSService.ps1 │ └── Set-ServiceRecovery.ps1 ├── TestFunctionality │ ├── Find-TypesNeeded.ps1 │ ├── Get-ModulesAvailability.ps1 │ ├── Search-Command.ps1 │ ├── Test-AvailabilityCommands.ps1 │ ├── Test-ComputerAvailability.ps1 │ ├── Test-ComputerPort.ps1 │ ├── Test-ConfigurationCredentials.ps1 │ ├── Test-ForestConnectivity.ps1 │ ├── Test-Key.ps1 │ ├── Test-ModuleAvailability.ps1 │ └── Test-WinRM.ps1 ├── Time │ ├── Get-TimeSettings.ps1 │ ├── Get-TimeZoneAdvanced.ps1 │ ├── Get-TimeZoneLegacy.ps1 │ ├── Measure-Collection.ps1 │ ├── Set-TimeSynchronization.ps1 │ ├── Start-TimeLog.ps1 │ └── Stop-TimeLog.ps1 ├── Vizualization │ ├── Show-Array.ps1 │ ├── Show-DataInVerbose.ps1 │ └── Show-TableVisualization.ps1 └── XML │ ├── Save-XML.ps1 │ └── Set-XML.ps1 ├── Readme.md └── Tests ├── Compare-MultipleObjects.Tests.ps1 ├── Convert-Identity.Tests.ps1 ├── ConvertFrom-DistinguishedName.Tests.ps1 ├── ConvertFrom-ObjectToString.Tests.ps1 ├── ConvertFrom-Sid.Tests.ps1 ├── ConvertTo-DistinguishedName.Tests.ps1 ├── ConvertTo-FlatObject.Tests.ps1 ├── ConvertTo-JsonLiteral.Tests.ps1 ├── ConvertTo-NormalizedString.Tests.ps1 ├── ConvertTo-PrettyObject.Tests.ps1 ├── Copy-DictionaryManual.Tests.ps1 ├── Format-ToTitleCase.Tests.ps1 ├── Format-Transpose.Tests.ps1 ├── Join-Uri.Tests.ps1 ├── Join-UriQuery.ps1 ├── Remove-EmptyValue.Tests.ps1 ├── Select-Properties.Tests.ps1 └── Test-IsDistinguishedName.Tests.ps1 /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: PrzemyslawKlys 4 | custom: https://paypal.me/PrzemyslawKlys -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | Ignore/* 2 | .vs/* 3 | Releases/* 4 | ReleasesUnpacked/* 5 | .vscode/* 6 | *.html 7 | Artefacts/* -------------------------------------------------------------------------------- /Docs/Convert-BinaryToHex.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Convert-BinaryToHex 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Convert-BinaryToHex [[-Binary] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Binary 34 | {{Fill Binary Description}} 35 | 36 | ```yaml 37 | Type: Byte[] 38 | Parameter Sets: (All) 39 | Aliases: Bin 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.Byte[] 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Convert-BinaryToString.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Convert-BinaryToString 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Convert-BinaryToString [[-Binary] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Binary 34 | {{Fill Binary Description}} 35 | 36 | ```yaml 37 | Type: Byte[] 38 | Parameter Sets: (All) 39 | Aliases: Bin 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.Byte[] 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Convert-HexToBinary.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Convert-HexToBinary 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Convert-HexToBinary [-Hex] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Hex 34 | {{Fill Hex Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: True 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.String 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Convert-KeyToKeyValue.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Convert-KeyToKeyValue 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Convert-KeyToKeyValue [[-Object] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Object 34 | {{Fill Object Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/ConvertFrom-OperationType.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # ConvertFrom-OperationType 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | ConvertFrom-OperationType [[-OperationType] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -OperationType 34 | {{Fill OperationType Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/ConvertFrom-SID.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # ConvertFrom-SID 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | ConvertFrom-SID [[-Sid] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Sid 34 | {{Fill Sid Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/ConvertTo-ImmutableID.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # ConvertFrom-SID 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | ConvertFrom-SID [[-Sid] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Sid 34 | {{Fill Sid Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Disconnect-WinService.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Disconnect-WinService 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Disconnect-WinService [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-ADConnectServer.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-ADConnectServer 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-ADConnectServer [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesCurrentDayMinusDayX.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesCurrentDayMinusDayX 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesCurrentDayMinusDayX [[-days] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -days 34 | {{Fill days Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-DatesCurrentDayMinuxDaysX.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesCurrentDayMinuxDaysX 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesCurrentDayMinuxDaysX [[-days] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -days 34 | {{Fill days Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-DatesCurrentHour.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesCurrentHour 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesCurrentHour [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesDayPrevious.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesDayPrevious 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesDayPrevious [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesDayToday.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesDayToday 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesDayToday [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesMonthCurrent.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesMonthCurrent 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesMonthCurrent [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesMonthPast.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesMonthPast 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesMonthPast [[-Force] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Force 34 | {{Fill Force Description}} 35 | 36 | ```yaml 37 | Type: Boolean 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-DatesPastHour.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesPastHour 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesPastHour [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-DatesPastWeek.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesPastWeek 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesPastWeek [[-DayName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -DayName 34 | {{Fill DayName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-DatesQuarterCurrent.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesQuarterCurrent 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesQuarterCurrent [[-Force] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Force 34 | {{Fill Force Description}} 35 | 36 | ```yaml 37 | Type: Boolean 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-DatesQuarterLast.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-DatesQuarterLast 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-DatesQuarterLast [[-Force] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Force 34 | {{Fill Force Description}} 35 | 36 | ```yaml 37 | Type: Boolean 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Find-ExchangeServer.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-ExchangeServer 9 | 10 | ## SYNOPSIS 11 | Find Exchange Servers in Active Directory 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-ExchangeServer [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | Find Exchange Servers in Active Directory 21 | 22 | ## EXAMPLES 23 | 24 | ### EXAMPLE 1 25 | ``` 26 | Find-ExchangeServer 27 | ``` 28 | 29 | ## PARAMETERS 30 | 31 | ### CommonParameters 32 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 33 | 34 | ## INPUTS 35 | 36 | ## OUTPUTS 37 | 38 | ## NOTES 39 | General notes 40 | 41 | ## RELATED LINKS 42 | -------------------------------------------------------------------------------- /Docs/Find-HyperVServer.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-HyperVServer 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-HyperVServer [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Find-ServerTypes.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-ServerTypes 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-ServerTypes [[-Type] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Type 34 | {{Fill Type Description}} 35 | 36 | ```yaml 37 | Type: String[] 38 | Parameter Sets: (All) 39 | Aliases: 40 | Accepted values: All, ADConnect, DomainController, Exchange, Hyper-V, RDSLicense, SQL, VirtualMachine 41 | 42 | Required: False 43 | Position: 0 44 | Default value: None 45 | Accept pipeline input: False 46 | Accept wildcard characters: False 47 | ``` 48 | 49 | ### CommonParameters 50 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 51 | 52 | ## INPUTS 53 | 54 | ### None 55 | 56 | ## OUTPUTS 57 | 58 | ### System.Object 59 | ## NOTES 60 | 61 | ## RELATED LINKS 62 | -------------------------------------------------------------------------------- /Docs/Find-UsersProxyAddressesStatus.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Find-UsersProxyAddressesStatus 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Find-UsersProxyAddressesStatus [[-User] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -User 34 | {{Fill User Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Format-ToTitleCase.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Format-ToTitleCase 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Format-ToTitleCase [-Text] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Text 34 | {{Fill Text Description}} 35 | 36 | ```yaml 37 | Type: String[] 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: True 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.String[] 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-CommandInfo.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-CommandInfo 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-CommandInfo [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-ComputerApplications.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerApplications 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerApplications [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerBios.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerBios 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerBios [[-ComputerName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. 50 | For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 51 | 52 | ## INPUTS 53 | 54 | ### None 55 | 56 | ## OUTPUTS 57 | 58 | ### System.Object 59 | ## NOTES 60 | 61 | ## RELATED LINKS 62 | -------------------------------------------------------------------------------- /Docs/Get-ComputerCulture.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerCulture 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerCulture [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerDiskLogical.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerDiskLogical 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerDiskLogical [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerMissingDrivers.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerMissingDrivers 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerMissingDrivers [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerNetwork.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerNetwork 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerNetwork [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerOemInformation.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerOemInformation 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerOemInformation [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerServices.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerServices 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerServices [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerStartup.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerStartup 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerStartup [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerWindowsFeatures.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerWindowsFeatures 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerWindowsFeatures [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-ComputerWindowsUpdates.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ComputerWindowsUpdates 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ComputerWindowsUpdates [[-ComputerName] ] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ## INPUTS 49 | 50 | ### None 51 | 52 | ## OUTPUTS 53 | 54 | ### System.Object 55 | ## NOTES 56 | 57 | ## RELATED LINKS 58 | -------------------------------------------------------------------------------- /Docs/Get-FileInformation.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-FileInformation 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-FileInformation [[-File] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -File 34 | {{Fill File Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-FileSize.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-FileSize 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-FileSize [[-Bytes] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Bytes 34 | {{Fill Bytes Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-HTML.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-HTML 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-HTML [[-text] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -text 34 | {{Fill text Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-IPAddressInformation.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-IPAddressInformation 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-IPAddressInformation [[-IP] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -IP 34 | {{Fill IP Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 1 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-MimeType.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-MimeType 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-MimeType [-FileName] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -FileName 34 | {{Fill FileName Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: True 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-ModulesAvailability.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ModulesAvailability 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ModulesAvailability [[-Name] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Name 34 | {{Fill Name Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-MyIpAddress.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-MyIpAddress 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-MyIpAddress [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-ObjectCount.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ObjectCount 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ObjectCount [[-Object] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Object 34 | {{Fill Object Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByPropertyName, ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.Object 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-ObjectEnumValues.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ObjectEnumValues 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ObjectEnumValues [[-enum] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -enum 34 | {{Fill enum Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-ObjectTitles.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ObjectTitles 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ObjectTitles [[-Object] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Object 34 | {{Fill Object Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-PathSeparator.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-PathSeparator 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-PathSeparator [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-PathTemporary.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-PathTemporary 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-PathTemporary [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-ServerRoles.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-ServerRoles 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-ServerRoles [[-ComputerName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. 50 | For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 51 | 52 | ## INPUTS 53 | 54 | ### None 55 | 56 | ## OUTPUTS 57 | 58 | ### System.Object 59 | ## NOTES 60 | 61 | ## RELATED LINKS 62 | -------------------------------------------------------------------------------- /Docs/Get-TimeSynchronization.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-TimeSynchronization 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-TimeSynchronization [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-TimeZoneLegacy.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-TimeZoneLegacy 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-TimeZoneLegacy [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Get-Types.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-Types 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-Types [[-Types] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Types 34 | {{Fill Types Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Get-WinADOrganizationalUnitFromDN.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-WinADOrganizationalUnitFromDN 9 | 10 | ## SYNOPSIS 11 | 12 | ## SYNTAX 13 | 14 | ``` 15 | Get-WinADOrganizationalUnitFromDN [[-DistinguishedName] ] [] 16 | ``` 17 | 18 | ## DESCRIPTION 19 | Long description 20 | 21 | ## EXAMPLES 22 | 23 | ### EXAMPLE 1 24 | ``` 25 | An example 26 | ``` 27 | 28 | $DistinguishedName = 'CN=Przemyslaw Klys,OU=Users,OU=Production,DC=ad,DC=evotec,DC=xyz' 29 | Get-WinADOrganizationalUnitFromDN -DistinguishedName $DistinguishedName 30 | 31 | ## PARAMETERS 32 | 33 | ### -DistinguishedName 34 | Parameter description 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 1 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ## OUTPUTS 54 | 55 | ## NOTES 56 | General notes 57 | 58 | ## RELATED LINKS 59 | -------------------------------------------------------------------------------- /Docs/Get-WinADUsersByOU.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Get-WinADUsersByOU 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Get-WinADUsersByOU [[-OrganizationalUnit] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -OrganizationalUnit 34 | {{Fill OrganizationalUnit Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/New-ArrayList.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # New-ArrayList 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | New-ArrayList [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/New-GenericList.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # New-GenericList 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | New-GenericList [[-Type] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Type 34 | {{Fill Type Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Remove-WhiteSpace.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Remove-WhiteSpace 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Remove-WhiteSpace [[-Text] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Text 34 | {{Fill Text Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Rename-LatinCharacters.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Rename-LatinCharacters 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Rename-LatinCharacters [[-String] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -String 34 | {{Fill String Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Search-Command.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Search-Command 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Search-Command [[-CommandName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -CommandName 34 | {{Fill CommandName Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Set-EmailHead.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Set-EmailHead 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Set-EmailHead [[-FormattingOptions] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -FormattingOptions 34 | {{Fill FormattingOptions Description}} 35 | 36 | ```yaml 37 | Type: IDictionary 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Set-EmailReportBranding.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Set-EmailReportBranding 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Set-EmailReportBranding [[-FormattingParameters] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -FormattingParameters 34 | {{Fill FormattingParameters Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: FormattingOptions 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Show-DataInVerbose.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Show-DataInVerbose 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Show-DataInVerbose [[-Object] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Object 34 | {{Fill Object Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Show-TableVisualization.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Show-TableVisualization 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Show-TableVisualization [[-Object] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Object 34 | {{Fill Object Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: True (ByPropertyName, ByValue) 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### System.Object 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Start-TimeLog.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Start-TimeLog 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Start-TimeLog [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Test-AvailabilityCommands.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Test-AvailabilityCommands 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Test-AvailabilityCommands [[-Commands] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -Commands 34 | {{Fill Commands Description}} 35 | 36 | ```yaml 37 | Type: String[] 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Test-ForestConnectivity.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Test-ForestConnectivity 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Test-ForestConnectivity [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Test-InstalledApplication.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Test-InstalledApplication 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Test-InstalledApplication [[-DisplayName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -DisplayName 34 | {{Fill DisplayName Description}} 35 | 36 | ```yaml 37 | Type: String 38 | Parameter Sets: (All) 39 | Aliases: ApplicationName 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Test-ModuleAvailability.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Test-ModuleAvailability 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Test-ModuleAvailability [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### CommonParameters 34 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 35 | 36 | ## INPUTS 37 | 38 | ### None 39 | 40 | ## OUTPUTS 41 | 42 | ### System.Object 43 | ## NOTES 44 | 45 | ## RELATED LINKS 46 | -------------------------------------------------------------------------------- /Docs/Test-WinRM.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Test-WinRM 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Test-WinRM [[-ComputerName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -ComputerName 34 | {{Fill ComputerName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Docs/Uninstall-ApplicationClickOnce.md: -------------------------------------------------------------------------------- 1 | --- 2 | external help file: PSSharedGoods-help.xml 3 | Module Name: PSSharedGoods 4 | online version: 5 | schema: 2.0.0 6 | --- 7 | 8 | # Uninstall-ApplicationClickOnce 9 | 10 | ## SYNOPSIS 11 | {{Fill in the Synopsis}} 12 | 13 | ## SYNTAX 14 | 15 | ``` 16 | Uninstall-ApplicationClickOnce [[-DisplayName] ] [] 17 | ``` 18 | 19 | ## DESCRIPTION 20 | {{Fill in the Description}} 21 | 22 | ## EXAMPLES 23 | 24 | ### Example 1 25 | ```powershell 26 | PS C:\> {{ Add example code here }} 27 | ``` 28 | 29 | {{ Add example description here }} 30 | 31 | ## PARAMETERS 32 | 33 | ### -DisplayName 34 | {{Fill DisplayName Description}} 35 | 36 | ```yaml 37 | Type: Object 38 | Parameter Sets: (All) 39 | Aliases: ApplicationName 40 | 41 | Required: False 42 | Position: 0 43 | Default value: None 44 | Accept pipeline input: False 45 | Accept wildcard characters: False 46 | ``` 47 | 48 | ### CommonParameters 49 | This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216). 50 | 51 | ## INPUTS 52 | 53 | ### None 54 | 55 | ## OUTPUTS 56 | 57 | ### System.Object 58 | ## NOTES 59 | 60 | ## RELATED LINKS 61 | -------------------------------------------------------------------------------- /Examples/Computer-Time.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSsharedGoods.psd1 -Force 2 | 3 | Get-ComputerTime -TimeTarget AD2, AD3, EVOWin | Format-Table -------------------------------------------------------------------------------- /Examples/ComputerDetails.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $Data = Get-Computer -ComputerName EVOWIN, AD1,AD2 -Verbose 4 | $Data 5 | $Data.RAM 6 | 7 | return 8 | 9 | New-HTML { 10 | New-HTMLTableOption -DataStore JavaScript 11 | New-HTMLTable -DataTable $Data.BIOS -Filtering 12 | New-HTMLTable -DataTable $Data.CPU -Filtering 13 | New-HTMLTable -DataTable $Data.RAM -Filtering 14 | New-HTMLTable -DataTable $Data.Disk -Filtering { 15 | New-HTMLTableCondition -Name 'FreePercent' -Value 32 -Color Red -ComparisonType number -Operator lt 16 | } 17 | New-HTMLTable -DataTable $Data.DiskLogical -Filtering { 18 | New-HTMLTableCondition -Name 'FreePercent' -Value 32 -Color Red -ComparisonType number -Operator lt 19 | } 20 | New-HTMLTable -DataTable $Data.OperatingSystem -Filtering 21 | New-HTMLTable -DataTable $Data.Services -Filtering 22 | New-HTMLTable -DataTable $Data.System -Filtering 23 | New-HTMLTable -DataTable $Data.Time -Filtering 24 | } -Online -FilePath $PSScriptRoot\Reports\ComputerInformation.html -ShowHTML -------------------------------------------------------------------------------- /Examples/ComputerDetails01.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | #Get-ComputerOperatingSystem -ComputerName AD1, AD2, AD3, DC1 -All #| ft -a * 4 | 5 | Get-ComputerTask | Format-Table 6 | 7 | #Get-ScheduledTask -TaskName 'Test' | fl * 8 | 9 | #Get-ScheduledTaskInfo -TaskName 'Test' | fl * -------------------------------------------------------------------------------- /Examples/ConvertCountry.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | Convert-CountryToCountryCode -CountryName 'VIETNAM' 4 | Convert-CountryToCountryCode -CountryName 'KOREA' 5 | Convert-CountryToCountryCode -CountryName 'CZECH REPUBLIC' 6 | Convert-CountryToCountryCode -CountryName 'VIET NAM' 7 | 8 | Convert-CountryCodeToCountry 'VN' 9 | Convert-CountryCodeToCountry 'KR' 10 | Convert-CountryCodeToCountry 'CZ' 11 | Convert-CountryCodeToCountry 'VN' -------------------------------------------------------------------------------- /Examples/ConvertFlatObject02.ps1: -------------------------------------------------------------------------------- 1 | Clear-Host 2 | Import-Module .\PSSharedGoods.psd1 -Force 3 | 4 | 5 | # $Object3 = [PSCustomObject] @{ 6 | # "Name" = "Przemyslaw Klys" 7 | # "Age" = "30" 8 | # "tEST" = @("test", 'test2') 9 | 10 | # } 11 | 12 | $MyObject = Get-AzureADMSConditionalAccessPolicy #| Where-Object { $_.DisplayName -eq "All - Deny Basic authentication" } 13 | $MyObject | ConvertTo-FlatObject -------------------------------------------------------------------------------- /Examples/ConvertIdentity2.ps1: -------------------------------------------------------------------------------- 1 |  2 | Import-Module $PSScriptRoot\..\PSSharedGoods.psd1 -Force 3 | 4 | @( 5 | $DN = 'CN=S-1-5-21-1928204107-2710010574-1926425344-512,CN=ForeignSecurityPrincipals,DC=ad,DC=evotec,DC=xyz' 6 | Convert-Identity -Identity $DN 7 | $DN = 'CN=Test Test 2,OU=Users,OU=Production,DC=ad,DC=evotec,DC=pl' 8 | Convert-Identity -Identity $DN 9 | $Group = Get-ADGroup -Identity 'Test Local Group' 10 | Convert-Identity -Identity $Group.SID.Value 11 | ) | Format-Table -------------------------------------------------------------------------------- /Examples/ConvertIdentity3.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSSharedGoods.psd1 -Force 2 | 3 | @( 4 | Convert-Identity -Identity 'CN=S-1-5-21-1928204107-2710010574-1926425344-512,CN=ForeignSecurityPrincipals,DC=ad,DC=evotec,DC=xyz' 5 | Convert-Identity -Identity 'CN=S-1-5-21-1928204107-2710010574-512,CN=ForeignSecurityPrincipals,DC=ad,DC=evotec,DC=xyz' -Verbose 6 | ) | Format-Table -------------------------------------------------------------------------------- /Examples/ConvertIdentity4.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSSharedGoods.psd1 -Force 2 | 3 | @( 4 | Convert-Identity -Identity 'CN=Test Test 2,OU=Users,OU=Production,DC=ad,DC=evotec,DC=pl' 5 | Convert-Identity -Identity 'NT AUTHORITY\INTERACTIVE' 6 | Convert-Identity -Identity 'INTERACTIVE' 7 | Convert-Identity -Identity 'EVOTEC\Domain Admins' 8 | Convert-Identity -Identity 'EVOTECPL\Domain Admins' 9 | Convert-Identity -Identity 'Test\Domain Admins' 10 | ) | Format-Table -------------------------------------------------------------------------------- /Examples/ConvertOffice365Licenses.ps1: -------------------------------------------------------------------------------- 1 | #Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | Convert-Office365License -License 'VISIOCLIENT','PROJECTONLINE_PLAN_1','test', 'tenant:VISIOCLIENT' 4 | Convert-Office365License -License "Office 365 (Plan A3) for Faculty","Office 365 (Enterprise Preview)", 'test' -ToSku 5 | 6 | -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson02.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $Test1 = [PSCustomObject] @{ 4 | Number = 1 5 | Bool = $false 6 | Array = @( 7 | 'C:\Users\1Password.exe' 8 | "C:\Users\Ooops.exe" 9 | "\\EvoWin\c$\Users\przemyslaw klys\AppData\Local\1password\This is other\7\1Password.exe" 10 | "\\EvoWin\c$\Users\przemyslaw.klys\AppData\Local\1password\This is other\7\1Password.exe" 11 | ) 12 | EmptyArray = @() 13 | EmptyList = [System.Collections.Generic.List[string]]::new() 14 | HashTable = @{ 15 | NumberAgain = 2 16 | OrderedDictionary = [ordered] @{ 17 | String = 'test' 18 | HashTable = @{ 19 | StringAgain = "oops" 20 | } 21 | } 22 | Array = @( 23 | 'C:\Users\1Password.exe' 24 | "C:\Users\Ooops.exe" 25 | "\\EvoWin\c$\Users\przemyslaw klys\AppData\Local\1password\This is other\7\1Password.exe" 26 | "\\EvoWin\c$\Users\przemyslaw.klys\AppData\Local\1password\This is other\7\1Password.exe" 27 | ) 28 | } 29 | DateTime = Get-Date 30 | } 31 | 32 | $Test2 = @{ 33 | Test1 = 1 34 | Test2 = 2 35 | Test3 = 3 36 | } 37 | 38 | $Test1 | ConvertTo-JsonLiteral -Depth 1 | ConvertFrom-Json 39 | $Test2 | ConvertTo-JsonLiteral -Depth 1 | ConvertFrom-Json -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson04.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | 4 | $Data = [PSCustomObject] @{ 5 | Test = 1 6 | Test2 = 2 7 | Test3 = [PSCustomObject] @{ 8 | IdontWantThat = 1 9 | } 10 | } 11 | 12 | New-HTML { 13 | New-HTMLTable -DataTable $Data -DataStore JavaScript 14 | } -FilePath $Env:USERPROFILE\Desktop\test.html -ShowHTML -Online 15 | 16 | return 17 | #Get-Process | Select-Object -First 2 | ConvertTo-JsonLiteral -Depth 0 18 | 19 | Get-Process | Select-Object -First 2 | ConvertTo-Json -Depth 1 #| ConvertFrom-Json 20 | 21 | return 22 | $Test = Get-Process | Select-Object -First 2 -Property Threads, TotalProcessorTime | ConvertTo-JsonLiteral -Depth 2 | ConvertFrom-Json 23 | $Test.Threads | Format-Table -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson05.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $Test = [PSCustomObject] @{ 4 | Number = 1 5 | Bool = $false 6 | 'Test.Value1.2' = '5' 7 | 'Test.Value1.3' = '6' 8 | } 9 | 10 | $Test, $Test, $Test | ConvertTo-JsonLiteral 11 | 12 | 13 | $Test = [PSCustomObject] @{ 14 | Number = 1 15 | Bool = $false 16 | 'Test.Value1.2' = '5' 17 | 'Test.Value1.3' = '6' 18 | } 19 | 20 | $Test | ConvertTo-Json -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson07.ps1: -------------------------------------------------------------------------------- 1 | #Import-Module PSWriteHTML -Force 2 | Import-Module .\PSSharedGoods.psd1 -Force 3 | 4 | $DataTable3 = @( 5 | [PSCustomObject] @{ 6 | 'property1' = 'Test1' 7 | 'property2' = 'Test2' 8 | } 9 | [PSCustomObject] @{ 10 | 'Property1' = 'Test1' 11 | 'Property2' = 'Test2' 12 | 'Property3' = 'Test3' 13 | } 14 | ) 15 | 16 | # This conversion shows how you can force JSON to use property names from either first element in array or even give it property names 17 | 18 | $DataTable3 | ConvertTo-JsonLiteral -Force | ConvertFrom-Json | Format-Table 19 | $DataTable3 | ConvertTo-JsonLiteral -PropertyName Property1, Property3 -Force | ConvertFrom-Json | Format-Table 20 | $DataTable3 | ConvertTo-JsonLiteral | ConvertFrom-Json | Format-Table 21 | $DataTable3 | ConvertTo-Json -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson08.ps1: -------------------------------------------------------------------------------- 1 | #Import-Module PSWriteHTML -Force 2 | Import-Module .\PSSharedGoods.psd1 -Force 3 | 4 | $DataTable3 = @( 5 | [PSCustomObject] @{ 6 | 'property1' = 'Test1' 7 | 'property2' = 'Test2' 8 | 'property3' = @( 9 | [PSCustomObject] @{ 10 | 'Property1' = 'Test1' 11 | 'Property2' = 'Test2' 12 | 'Property3' = 'Test3' 13 | } 14 | [PSCustomObject] @{ 15 | 'Property1' = 'Test1' 16 | 'Property2' = 'Test2' 17 | 'Property3' = 'Test3' 18 | } 19 | [PSCustomObject] @{ 20 | 'property1' = 'Test1' 21 | 'property2' = 'Test2' 22 | 'property3' = 'Test3' 23 | } 24 | ) 25 | } 26 | [PSCustomObject] @{ 27 | 'Property1' = 'Test1' 28 | 'Property2' = 'Test2' 29 | 'Property3' = 'Test3' 30 | } 31 | ) 32 | 33 | # This conversion shows how you can force JSON to use property names from either first element in array or even give it property names 34 | 35 | $DataTable3 | ConvertTo-JsonLiteral -Force -Depth 2 -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson10.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $T = Get-HotFix -ComputerName AD1 | Sort-Object -Property InstalledOn -Descending | Select-Object -First 1 4 | 5 | $T | ConvertTo-Json 6 | $T | ConvertTo-JsonLiteral -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson11.ps1: -------------------------------------------------------------------------------- 1 |  2 | 3 | [Array] $ConditionsContainer = @( 4 | [ordered]@{ 5 | logic = 'AND' 6 | conditions = @( 7 | [ordered] @{ 8 | columnName = 'name' 9 | columnId = 5 10 | operator = 'eq' 11 | type = 'test' 12 | value = 1.23 13 | dataStore = 'html' 14 | caseInsensitive = $false 15 | } 16 | 17 | ) 18 | } 19 | ) 20 | 21 | $ConditionsContainer | ConvertTo-JsonLiteral -Depth 5 -AsArray -------------------------------------------------------------------------------- /Examples/ConvertTo-JSON/ConvertToJson12.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $PSCustomObject = [PSCustomObject] @{ 4 | Test1 = 1 5 | Test2 = 1.2 6 | Test3 = 1.2, 1.3, 1.4 7 | Test4 = 1, 2, 3, 4, 5 8 | Test5 = 1, 1.2, 1.3, 4 9 | } 10 | 11 | $PSCustomObject | ConvertTo-JsonLiteral -Depth 2 | ConvertFrom-Json #-NumberAsString 12 | #$PSCustomObject | ConvertTo-Json -------------------------------------------------------------------------------- /Examples/CopyDictionary.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | $ExtendedForestInformation = Get-WinADForestDetails -Extended 4 | $ExtendedForestInformation | Format-Table 5 | $New = Copy-Dictionary -Dictionary $ExtendedForestInformation 6 | $New | Format-Table -------------------------------------------------------------------------------- /Examples/CopyDictionary1.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | $Object = @{ 4 | String = 'test' 5 | AnotherObject = [ordered] @{ 6 | Value1 = 1 7 | Value2 = 2 8 | Value3 = 2 9 | Value4 = 2 10 | Value5 = 2 11 | } 12 | SomethingElse = [PSCustomObject] @{ 13 | Value1 = 1 14 | Value2 = 2 15 | } 16 | ScriptBlock = { 17 | Get-ChildItem 18 | } 19 | } 20 | 21 | $NewObject = Copy-Dictionary -Dictionary $Object 22 | $NewObject.SomethingElse.Value1 = 5 23 | $NewObject.AnotherObject.Value1 = 5 24 | 25 | $NewObject.AnotherObject.Value1 | Should -Be 5 26 | $NewObject.SomethingElse.Value1 | Should -Be 5 27 | $NewObject.ScriptBlock | Should -Be $Object.ScriptBlock -------------------------------------------------------------------------------- /Examples/Example-01-FileMetaData.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | # Option 1 4 | Get-ChildItem -Path $Env:USERPROFILE\Desktop -Force | Get-FileMetaData -Signature -HashAlgorithm SHA256 | Out-HtmlView -ScrollX -Filtering -AllProperties 5 | return 6 | # Option 2 7 | $Files = "$Env:USERPROFILE\Desktop\LAPS.x64.msi", "$Env:USERPROFILE\Desktop\DigiCertUtil.exe" 8 | $Files | Get-FileMetaData -Signature -HashAlgorithm MD5 | Out-HtmlView -ScrollX -Filtering -AllProperties 9 | 10 | # Option 3 11 | Get-FileMetaData -File $Files -Signature | Out-HtmlView -ScrollX -Filtering -AllProperties 12 | 13 | # Option 4 14 | Get-ChildItem -Path $Env:USERPROFILE\Desktop -Force | Where-Object { $_.Attributes -like '*Hidden*' } | Get-FileMetaData -Signature | Out-HtmlView -ScrollX -Filtering -AllProperties 15 | 16 | # Option 5 17 | $Files = "$Env:USERPROFILE\Desktop\LAPS.x64.msi", "$Env:USERPROFILE\Desktop\DigiCertUtil.exe" 18 | $Files | Get-FileMetaData -Signature | Format-List -------------------------------------------------------------------------------- /Examples/Example-02-OperatingSystemTranslation.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | $Computers = Get-ADComputer -Filter * -Properties OperatingSystem, OperatingSystemVersion | ForEach-Object { 4 | $OPS = ConvertTo-OperatingSystem -OperatingSystem $_.OperatingSystem -OperatingSystemVersion $_.OperatingSystemVersion 5 | Add-Member -MemberType NoteProperty -Name 'OperatingSystemTranslated' -Value $OPS -InputObject $_ -Force 6 | $_ 7 | } 8 | $Computers | Select-Object DNS*, Name, SamAccountName, Enabled, OperatingSystem*, DistinguishedName | Format-Table -------------------------------------------------------------------------------- /Examples/File-Permissions.ps1: -------------------------------------------------------------------------------- 1 | $Path = "F:\Shares\PersonalTesting" 2 | 3 | function Find-AndFixFolders { 4 | param( 5 | $Path 6 | ) 7 | $folders = Get-ChildItem -Path $path -Directory | Select-Object Name, FullName 8 | foreach ($folder in $folders) { 9 | Set-FileInheritance $folder.FullName -DisableInheritance # -KeepInheritedAcl 10 | #Remove-FilePermission $folder.FullName -UserOrGroup "Domain\srv.pklys" 11 | #Remove-FilePermission $folder.FullName -All 12 | Set-FilePermission $folder.FullName -UserOrGroup "Domain\$($folder.Name)" -AclRightsToAssign "ReadAndExecute" 13 | Set-FilePermission $folder.FullName -UserOrGroup "Domain\Domain Admins" -AclRightsToAssign "FullControl" 14 | Set-FilePermission $folder.FullName -UserOrGroup "BUILTIN\Administrators" -AclRightsToAssign "FullControl" 15 | Set-FilePermission $folder.FullName -UserOrGroup "BUILTIN\Administrators" -AclRightsToAssign "FullControl" 16 | Set-FilePermission $folder.FullName -UserOrGroup "SYSTEM" -AclRightsToAssign "FullControl" 17 | Set-FilePermission $folder.FullName -UserOrGroup "Domain\domain.pklys" -AclRightsToAssign "FullControl" 18 | Remove-FilePermission $folder.FullName -UserOrGroup "BUILTIN\Users" 19 | } 20 | } 21 | 22 | Find-AndFixFolders -Path $Path -------------------------------------------------------------------------------- /Examples/File-Permissions01.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | Get-FilePermissions -Path '\\ad.evotec.xyz\Netlogon\New folder' -Extended | Format-Table 4 | Get-FilePermissions -Path '\\ad.evotec.pl\Netlogon\New folder (3)' -Extended | Format-Table 5 | #Get-FilePermissions -Path '\\ad.evotec.xyz\Netlogon\Signatures' | Format-Table -------------------------------------------------------------------------------- /Examples/File-Permissions02.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | $Path = Get-ChildItem '\\ad.evotec.xyz\SYSVOL\ad.evotec.xyz\scripts' -Recurse 4 | 5 | Get-FilePermission -Path $Path | Format-Table -------------------------------------------------------------------------------- /Examples/Format-Stream1.ps1: -------------------------------------------------------------------------------- 1 | $InvoiceEntry1 = [ordered] @{} 2 | $InvoiceEntry1.Description = 'IT Services 1' 3 | $InvoiceEntry1.Amount = '$200' 4 | 5 | $InvoiceEntry2 = @{} 6 | $InvoiceEntry2.Description = 'IT Services 2' 7 | $InvoiceEntry2.Amount = '$300' 8 | 9 | $InvoiceEntry3 = @{} 10 | $InvoiceEntry3.Description = 'IT Services 3' 11 | $InvoiceEntry3.Amount = '$288' 12 | 13 | $InvoiceEntry4 = @{} 14 | $InvoiceEntry4.Description = 'IT Services 4' 15 | $InvoiceEntry4.Amount = '$301' 16 | 17 | $InvoiceEntry5 = @{} 18 | $InvoiceEntry5.Description = 'IT Services 5' 19 | $InvoiceEntry5.Amount = '$299' 20 | 21 | $InvoiceData1 = @() 22 | $InvoiceData1 += $InvoiceEntry1 23 | $InvoiceData1 += $InvoiceEntry2 24 | $InvoiceData1 += $InvoiceEntry3 25 | $InvoiceData1 += $InvoiceEntry4 26 | $InvoiceData1 += $InvoiceEntry5 27 | 28 | 29 | $InvoiceData1 | Format-Stream -Transpose -TransposeSort ASC -Stream Host -Color Green,Red -ColorRow 2,4 -------------------------------------------------------------------------------- /Examples/Format-Stream2.ps1: -------------------------------------------------------------------------------- 1 | #get-process | Select-Object -First 5 | Format-Stream Name, PriorityClass, HandleCount -List -Stream Output # | Add-Content -Path 'C:\Test.txt' 2 | Get-Process | Select-Object -First 5 | Format-Stream Name, PriorityClass, HandleCount -List -Stream Debug 3 | Get-Process | Select-Object -First 5 | Format-Stream Name, PriorityClass, HandleCount -Stream Output | Add-Content -Path 'C:\Test.txt' 4 | 5 | #get-process | Select-Object -First 5 | Format-TableVerbose Name, PriorityClass, HandleCount #, FileVersion, Handles, Id, Si , StartInfo, MainModule 6 | Get-Process | Select-Object -First 5 | Format-Stream Name, PriorityClass, HandleCount , FileVersion, Handles, Id, Si , StartInfo, MainModule -Stream 'Warning' 7 | Get-Process | Select-Object -First 5 | Format-Stream Id, Si , StartInfo, MainModule -Stream Information 8 | 9 | Get-Process | Select-Object -First 5 | Format-Stream * 10 | 11 | Get-Process | Select-Object -First 5 | Format-Stream * -HideTableHeaders # Id, Si , StartInfo, MainModule 12 | 13 | Get-Process | Select-Object -First 5 | Format-Stream * -AlignRight # Id, Si , StartInfo, MainModule 14 | 15 | $Process = Get-Process | Select-Object -First 5 16 | Format-Stream -InputObject $Process -ExcludeProperty Company, CPU -ColumnHeaderSize 15 -------------------------------------------------------------------------------- /Examples/Format-Stream3.ps1: -------------------------------------------------------------------------------- 1 | Clear-Host 2 | Get-Process | Select-Object -First 5 | Format-Stream * -Stream Host -ForegroundColor Green,Red, Yellow -ForegroundColorRow 2,4,5 3 | Get-Process | Select-Object -First 5 | Format-Stream Name,ID -Stream Host -ForegroundColor Green,Red, Yellow -ForegroundColorRow 2,4,5 4 | Get-Process | Select-Object -First 5 | Format-Stream Name,ID -Stream Host -List -------------------------------------------------------------------------------- /Examples/FunTest0.ps1: -------------------------------------------------------------------------------- 1 | # Some input data - simplified for example purposes 2 | $SomeData = @('be', 'me', 'one', 'more', 'time') 3 | 4 | $GenericList1 = [System.Collections.Generic.List[Object]]::new() 5 | $GenericList2 = [System.Collections.Generic.List[Object]]::new() 6 | 7 | foreach ($Something in $SomeData) { 8 | $GenericList1.Add("MyValue $Something") 9 | $GenericList2.Add("Other $Something") 10 | } 11 | 12 | $GenericList1.Count 13 | $GenericList2.Count 14 | 15 | $GenericList1.Remove('MyValue be') 16 | $GenericList1.Count 17 | $GenericList1 -join ',' 18 | -------------------------------------------------------------------------------- /Examples/FunTest3.ps1: -------------------------------------------------------------------------------- 1 | $Object1 = @{ 2 | Name = 'Test1' 3 | Status = 1 4 | } 5 | $Object2 = @{ 6 | Name = 'Tests2' 7 | Status = $null 8 | } 9 | 10 | $Array = @($Object1, $Object2) 11 | 12 | $Test1 = While ($Array.Status -ne $null) { 13 | $true 14 | foreach ($A in $Array) { 15 | $A.Status = $null 16 | } 17 | } 18 | 19 | $Test1 20 | 21 | $Test2 = While ($null -ne $Array.Status) { 22 | $true 23 | foreach ($A in $Array) { 24 | $A.Status = $null 25 | } 26 | } 27 | 28 | # This will never end.... 29 | 30 | $Test2 -------------------------------------------------------------------------------- /Examples/GetDomainControllers.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSsharedGoods.psd1 -Force 2 | 3 | $ForestInformation = Get-WinADForestDetails -Extended #-IncludeDomains 'ad.evotec.pl' -ExcludeDomainControllers adpreview2019 4 | #$ForestInformation.ForestDomainControllers | ft -AutoSize 5 | $F2 = Copy-Dictionary $ForestInformation 6 | 7 | $F = Get-WinADForestDetails -ExtendedForestInformation $ForestInformation -IncludeDomains 'ad.evotec.pl' -ExcludeDomainControllers adpreview2019 8 | $F.ForestDomainControllers | Format-Table -AutoSize 9 | 10 | $F2 = Copy-Dictionary $F 11 | 12 | Get-WinADForestDetails -ExtendedForestInformation $F2 #-IncludeDomains 'ad.evotec.pl' -ExcludeDomainControllers adpreview2019 -------------------------------------------------------------------------------- /Examples/GetDotNet.ps1: -------------------------------------------------------------------------------- 1 |  2 | $PSVersionTable 3 | $PSVersionTable.DotNetVersion = [System.Runtime.InteropServices.RuntimeInformation]::FrameworkDescription 4 | $PSVersionTable.OSArchitecture = [System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture 5 | 6 | [version]([System.Runtime.InteropServices.RuntimeInformation]::FrameworkDescription -split '\s' | Select-Object -Last 1) 7 | 8 | [version][regex]::Match([System.Runtime.InteropServices.RuntimeInformation]::FrameworkDescription, '(\d\.?){3,}$').Value -------------------------------------------------------------------------------- /Examples/OperatingSystemsVersions.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSsharedGoods.psd1 -Force 2 | 3 | Get-OperatingSystem | Format-Table 4 | 5 | Get-OperatingSystem | Out-HtmlView { 6 | 7 | } -DateTimeSortingFormat 'DD.MM.YYYY HH:mm:ss' 8 | 9 | 10 | Get-OperatingSystem -Version '10.0 (19043)' | Format-Table -------------------------------------------------------------------------------- /Examples/Permissions.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | #Get-ChildItem -Path '\\ad1\c$\Windows\SYSVOL\sysvol\ad.evotec.xyz\scripts\Signatures\New folder' | ForEach-Object { 4 | # Get-FilePermission -path $_ -ResolveTypes 5 | #} | Format-Table * 6 | $Test = '\\ad1\c$\Windows\SYSVOL\sysvol\ad.evotec.xyz\scripts\Signatures\New folder' 7 | $Test = '\\ad.evotec.xyz\NETLOGON' 8 | 9 | Get-FileOwner -Path $Test -Resolve 10 | Get-FilePermission -Path $Test -Resolve -IncludeACLObject | Format-Table * 11 | #Get-WinADShare -Path $Test | Format-Table * 12 | 13 | #Get-WinADShare -Type NetLogon -Owner | Format-Table * -------------------------------------------------------------------------------- /Examples/RegistryNew.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | New-PSRegistry -RegistryPath "HKCU:\\Tests1\CurrentControlSet\Control\Lsa" -Verbose -WhatIf | Format-Table 4 | Get-PSRegistry -RegistryPath "HKCU:\\Tests1\CurrentControlSet\Control\Lsa" -Verbose | Format-Table 5 | 6 | New-PSRegistry -RegistryPath "HKUDUO:\\Tests1\CurrentControlSet\Control\Lsa" -WhatIf | Format-Table 7 | Get-PSRegistry -RegistryPath "HKUDUO:\Tests1\CurrentControlSet\Control\Lsa" | Format-Table -------------------------------------------------------------------------------- /Examples/RegistryRemove.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | Remove-PSRegistry -RegistryPath "HKEY_CURRENT_USER\Tests\Ok\MaybeNot" -Key "LimitBlankPass1wordUse" -WhatIf 4 | Remove-PSRegistry -RegistryPath "HKCU:\Tests\Ok" -WhatIf 5 | 6 | Remove-PSRegistry -RegistryPath "HKUDUO:\\Tests1\CurrentControlSet\Control\Lsa" -WhatIf | Format-Table 7 | Get-PSRegistry -RegistryPath "HKUDUO:\Tests1\CurrentControlSet\Control\Lsa" | Format-Table -------------------------------------------------------------------------------- /Examples/RemoveFiles.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | Remove-FileItem -Paths "C:\Temp\New folder" -DeleteMethod RecycleBin -Recursive -Passthru #-SkipFolder -------------------------------------------------------------------------------- /Examples/Services.ps1: -------------------------------------------------------------------------------- 1 | Import-Module $PSScriptRoot\..\PSsharedGoods.psd1 -Force 2 | 3 | $DomainController = 'ad1.ad.evotec.xyz', 'ad2' 4 | $Services = @('ADWS', 'DNS', 'DFS', 'DFSR', 'Eventlog', 'EventSystem', 'KDC', 'LanManWorkstation', 'LanManServer', 'NetLogon', 'NTDS', 'RPCSS', 'SAMSS', 'Spooler', 'W32Time', 'XblGameSave', 'XblAuthManager') 5 | Get-PSService -Computers $DomainController -Services $Services | Format-Table -------------------------------------------------------------------------------- /Examples/TestIP.ps1: -------------------------------------------------------------------------------- 1 | Import-Module .\PSSharedGoods.psd1 -Force 2 | 3 | $CidrObject = @{ 4 | Ip = '10.2.10.0' 5 | NetworkLength = 24 6 | } 7 | Get-IPAddressRangeInformation -CIDRObject $CidrObject | Format-Table 8 | 9 | Get-IPAddressRangeInformation -Network '10.2.10.0/24' | Format-Table 10 | 11 | Get-IPAddressRangeInformation -IPAddress '10.2.10.0' -NetworkLength 24 | Format-Table -------------------------------------------------------------------------------- /License: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Evotec 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /PSSharedGoods.AzurePipelines.Linux.yml: -------------------------------------------------------------------------------- 1 | jobs: 2 | - job: Build_PSCore_Ubuntu1604 3 | pool: 4 | vmImage: ubuntu-latest 5 | steps: 6 | - script: | 7 | curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add - 8 | curl https://packages.microsoft.com/config/ubuntu/16.04/prod.list | sudo tee /etc/apt/sources.list.d/microsoft.list 9 | sudo apt-get update 10 | sudo apt-get install -y powershell 11 | displayName: "Install PowerShell Core" 12 | - script: | 13 | pwsh -c '.\PSSharedGoods.Tests.ps1' 14 | displayName: "Run Pester Tests" -------------------------------------------------------------------------------- /PSSharedGoods.AzurePipelines.macOs.yml: -------------------------------------------------------------------------------- 1 | jobs: 2 | - job: Build_PSCore_MacOS1013 3 | pool: 4 | vmImage: macOS-latest 5 | steps: 6 | - script: | 7 | brew update 8 | brew tap caskroom/cask 9 | brew install mono-libgdiplus 10 | brew cask install powershell 11 | displayName: "Install PowerShell Core" 12 | - script: | 13 | pwsh -c '.\PSSharedGoods.Tests.ps1' 14 | displayName: "Run Pester Tests" 15 | -------------------------------------------------------------------------------- /PSSharedGoods.AzurePipelines.yml: -------------------------------------------------------------------------------- 1 | jobs: 2 | - job: Build_PS_Win2016 3 | displayName: "Windows Tests" 4 | pool: 5 | vmImage: windows-latest 6 | steps: 7 | - powershell: | 8 | Install-Module -Name Pester -Repository PSGallery -Force -SkipPublisherCheck 9 | .\PSSharedGoods.Tests.ps1 10 | displayName: "Run Pester Tests - PowerShell 5" 11 | # - script: | 12 | # pwsh -c '.\PSWritePDF.Tests.ps1' 13 | # displayName: "Run Pester Tests - PowerShell 6+" -------------------------------------------------------------------------------- /Private/Convert-BinaryToIP.ps1: -------------------------------------------------------------------------------- 1 | function Convert-BinaryToIP { 2 | <# 3 | .SYNOPSIS 4 | Converts a binary string to an IP address format. 5 | 6 | .DESCRIPTION 7 | This function takes a binary string as input and converts it to an IP address format. The binary string must be evenly divisible by 8. 8 | 9 | .PARAMETER Binary 10 | The binary string to convert to an IP address format. 11 | 12 | .EXAMPLE 13 | Convert-BinaryToIP -Binary "01000001000000100000000100000001" 14 | Output: 65.0.1.1 15 | #> 16 | [cmdletBinding()] 17 | param( 18 | [string] $Binary 19 | ) 20 | $Binary = $Binary -replace '\s+' 21 | if ($Binary.Length % 8) { 22 | Write-Warning -Message "Convert-BinaryToIP - Binary string '$Binary' is not evenly divisible by 8." 23 | return $Null 24 | } 25 | [int] $NumberOfBytes = $Binary.Length / 8 26 | $Bytes = @(foreach ($i in 0..($NumberOfBytes - 1)) { 27 | try { 28 | #$Bytes += # skipping this and collecting "outside" seems to make it like 10 % faster 29 | [System.Convert]::ToByte($Binary.Substring(($i * 8), 8), 2) 30 | } catch { 31 | Write-Warning -Message "Convert-BinaryToIP - Error converting '$Binary' to bytes. `$i was $i." 32 | return $Null 33 | } 34 | }) 35 | return $Bytes -join '.' 36 | } -------------------------------------------------------------------------------- /Private/Convert-IPToBinary.ps1: -------------------------------------------------------------------------------- 1 | function Convert-IPToBinary { 2 | <# 3 | .SYNOPSIS 4 | Converts an IPv4 address to binary format. 5 | 6 | .DESCRIPTION 7 | This function takes an IPv4 address as input and converts it to binary format. 8 | 9 | .PARAMETER IP 10 | Specifies the IPv4 address to convert to binary format. 11 | 12 | .EXAMPLE 13 | Convert-IPToBinary -IP "192.168.1.1" 14 | Converts the IPv4 address "192.168.1.1" to binary format. 15 | 16 | .EXAMPLE 17 | Convert-IPToBinary -IP "10.0.0.1" 18 | Converts the IPv4 address "10.0.0.1" to binary format. 19 | 20 | #> 21 | [cmdletBinding()] 22 | param( 23 | [string] $IP 24 | ) 25 | $IPv4Regex = '(?:(?:0?0?\d|0?[1-9]\d|1\d\d|2[0-5][0-5]|2[0-4]\d)\.){3}(?:0?0?\d|0?[1-9]\d|1\d\d|2[0-5][0-5]|2[0-4]\d)' 26 | $IP = $IP.Trim() 27 | if ($IP -match "\A${IPv4Regex}\z") { 28 | try { 29 | return ($IP.Split('.') | ForEach-Object { [System.Convert]::ToString([byte] $_, 2).PadLeft(8, '0') }) -join '' 30 | } catch { 31 | Write-Warning -Message "Convert-IPToBinary - Error converting '$IP' to a binary string: $_" 32 | return $Null 33 | } 34 | } else { 35 | Write-Warning -Message "Convert-IPToBinary - Invalid IP detected: '$IP'. Conversion failed." 36 | return $Null 37 | } 38 | } -------------------------------------------------------------------------------- /Private/ConvertFrom-HTML.ps1: -------------------------------------------------------------------------------- 1 | function ConvertFrom-HTML { 2 | <# 3 | .SYNOPSIS 4 | Converts HTML strings to plain text. 5 | 6 | .DESCRIPTION 7 | This function converts HTML strings to plain text. It can also remove HTML tags if specified. 8 | 9 | .PARAMETER HTML 10 | Specifies the HTML strings to convert. 11 | 12 | .PARAMETER RemoveTags 13 | Indicates whether to remove HTML tags from the input HTML strings. 14 | 15 | .EXAMPLE 16 | ConvertFrom-HTML -HTML "

Hello, World!

" -RemoveTags 17 | This example converts the HTML string "

Hello, World!

" to plain text and removes the HTML tags. 18 | 19 | #> 20 | [alias('Convert-HTMLToString')] 21 | [CmdletBinding()] 22 | param( 23 | [string[]] $HTML, 24 | [switch] $RemoveTags 25 | ) 26 | foreach ($H in $HTML) { 27 | if ($RemoveTags) { 28 | # this removes things like between brackets like

or

29 | $H = $H -replace '<[^>]+>', '' 30 | } 31 | # This replaces chars to their clean equivalent 32 | $H -replace '“', '"' -replace '’', "'" -replace '”', '"' -replace '…', '...' -replace '—', '-' -replace '–', '-' 33 | } 34 | } -------------------------------------------------------------------------------- /Private/Deprecated/ActiveDirectory/Find-ExchangeServer.ps1: -------------------------------------------------------------------------------- 1 | function Find-ExchangeServer { 2 | <# 3 | .SYNOPSIS 4 | Find Exchange Servers in Active Directory 5 | 6 | .DESCRIPTION 7 | Find Exchange Servers in Active Directory 8 | 9 | .EXAMPLE 10 | Find-ExchangeServer 11 | 12 | .NOTES 13 | General notes 14 | #> 15 | [CmdletBinding()] 16 | param( 17 | 18 | ) 19 | $ExchangeServers = Get-ADGroup -Identity "Exchange Servers" 20 | foreach ($Server in $ExchangeServers) { 21 | $Data = Get-ADComputer -Identity $Server.SamAccountName -Properties Name, DNSHostName, OperatingSystem, DistinguishedName, ServicePrincipalName 22 | [PSCustomObject] @{ 23 | Name = $Data.Name 24 | FQDN = $Data.DNSHostName 25 | OperatingSystem = $Data.OperatingSystem 26 | DistinguishedName = $Data.DistinguishedName 27 | Enabled = $Data.Enabled 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /Private/Deprecated/ActiveDirectory/Get-WinADOrganizationalUnitFromDN.ps1: -------------------------------------------------------------------------------- 1 | function Get-WinADOrganizationalUnitFromDN { 2 | <# 3 | .SYNOPSIS 4 | This function extracts the Organizational Unit (OU) from a given Distinguished Name (DN). 5 | 6 | .DESCRIPTION 7 | This function takes a Distinguished Name (DN) as input and returns the Organizational Unit (OU) part of it. 8 | 9 | .PARAMETER DistinguishedName 10 | Specifies the Distinguished Name (DN) from which to extract the Organizational Unit (OU). 11 | 12 | .EXAMPLE 13 | Extract the Organizational Unit (OU) from a Distinguished Name. 14 | 15 | $DistinguishedName = 'CN=Przemyslaw Klys,OU=Users,OU=Production,DC=ad,DC=evotec,DC=xyz' 16 | Get-WinADOrganizationalUnitFromDN -DistinguishedName $DistinguishedName 17 | 18 | .NOTES 19 | This function uses regular expressions to extract the Organizational Unit (OU) from the given Distinguished Name (DN). 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | $DistinguishedName 24 | ) 25 | return [Regex]::Match($DistinguishedName,'(?=OU)(.*\n?)(?<=.)').Value 26 | } -------------------------------------------------------------------------------- /Private/Deprecated/ActiveDirectory/Get-WinADUsersByOU.ps1: -------------------------------------------------------------------------------- 1 | function Get-WinADUsersByOU { 2 | <# 3 | .SYNOPSIS 4 | Retrieves Active Directory users within a specified Organizational Unit. 5 | 6 | .DESCRIPTION 7 | This function retrieves Active Directory users within the specified Organizational Unit. 8 | 9 | .PARAMETER OrganizationalUnit 10 | Specifies the Organizational Unit from which to retrieve users. 11 | 12 | .EXAMPLE 13 | Get-WinADUsersByOU -OrganizationalUnit "OU=Sales,DC=Contoso,DC=com" 14 | Retrieves all users within the Sales Organizational Unit in the Contoso domain. 15 | 16 | #> 17 | [CmdletBinding()] 18 | param ( 19 | $OrganizationalUnit 20 | ) 21 | $OU = Get-ADOrganizationalUnit $OrganizationalUnit 22 | if ($OU.ObjectClass -eq 'OrganizationalUnit') { 23 | try { 24 | $Users = Get-ADUser -SearchBase $OU -Filter * -Properties $Script:UserProperties 25 | } catch { 26 | Write-Color @Script:WriteParameters -Text '[i]', ' One or more properties are invalid - Terminating', ' Terminating' -Color Yellow, White, Red 27 | return 28 | } 29 | } 30 | return $Users 31 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesCurrentDayMinusDayX.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesCurrentDayMinusDayX ($days) { 2 | <# 3 | .SYNOPSIS 4 | Finds the date range for the current day minus a specified number of days. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates for the current day minus a specified number of days. 8 | 9 | .PARAMETER days 10 | Specifies the number of days to subtract from the current day. 11 | 12 | .EXAMPLE 13 | Find-DatesCurrentDayMinusDayX -days 1 14 | Returns the date range for yesterday. 15 | 16 | .EXAMPLE 17 | Find-DatesCurrentDayMinusDayX -days 7 18 | Returns the date range for a week ago. 19 | 20 | #> 21 | $DateTodayStart = (Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0).AddDays( - $Days) 22 | $DateTodayEnd = (Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0).AddDays(1).AddDays( - $Days).AddMilliseconds(-1) 23 | 24 | $DateParameters = @{ 25 | DateFrom = $DateTodayStart 26 | DateTo = $DateTodayEnd 27 | } 28 | return $DateParameters 29 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesCurrentDayMinuxDaysX.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesCurrentDayMinuxDaysX ($days) { 2 | <# 3 | .SYNOPSIS 4 | Finds the date range for the current day minus a specified number of days. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates for the current day minus a specified number of days. 8 | 9 | .PARAMETER days 10 | Specifies the number of days to subtract from the current day. 11 | 12 | .EXAMPLE 13 | Find-DatesCurrentDayMinuxDaysX -days 1 14 | Returns the date range for yesterday. 15 | 16 | .EXAMPLE 17 | Find-DatesCurrentDayMinuxDaysX -days 7 18 | Returns the date range for a week ago. 19 | #> 20 | $DateTodayStart = (Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0).AddDays( - $Days) 21 | $DateTodayEnd = (Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0).AddDays(1).AddMilliseconds(-1) 22 | 23 | $DateParameters = @{ 24 | DateFrom = $DateTodayStart 25 | DateTo = $DateTodayEnd 26 | } 27 | return $DateParameters 28 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesCurrentHour.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesCurrentHour () { 2 | <# 3 | .SYNOPSIS 4 | Finds the start and end dates for the current hour. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates for the current hour. 8 | 9 | .EXAMPLE 10 | PS C:\> Find-DatesCurrentHour 11 | DateFrom DateTo 12 | -------- ------ 13 | 10/20/2021 12:00:00 AM 10/20/2021 1:00:00 AM 14 | #> 15 | $DateTodayStart = (Get-Date -Minute 0 -Second 0 -Millisecond 0) 16 | $DateTodayEnd = $DateTodayStart.AddHours(1) 17 | 18 | $DateParameters = @{ 19 | DateFrom = $DateTodayStart 20 | DateTo = $DateTodayEnd 21 | } 22 | return $DateParameters 23 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesDayPrevious.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesDayPrevious () { 2 | <# 3 | .SYNOPSIS 4 | Finds the date parameters for the previous day. 5 | 6 | .DESCRIPTION 7 | This function calculates the date parameters for the previous day based on the current date. 8 | 9 | .EXAMPLE 10 | Find-DatesDayPrevious 11 | Returns the date parameters for the previous day. 12 | 13 | #> 14 | $DateToday = (GET-DATE).Date 15 | $DateYesterday = $DateToday.AddDays(-1) 16 | 17 | $DateParameters = @{ 18 | DateFrom = $DateYesterday 19 | DateTo = $dateToday 20 | } 21 | return $DateParameters 22 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesDayToday.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesDayToday () { 2 | <# 3 | .SYNOPSIS 4 | Finds the start and end dates of the current day. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates of the current day based on the current date. 8 | #> 9 | $DateToday = (GET-DATE).Date 10 | $DateTodayEnd = $DateToday.AddDays(1).AddSeconds(-1) 11 | 12 | $DateParameters = @{ 13 | DateFrom = $DateToday 14 | DateTo = $DateTodayEnd 15 | } 16 | return $DateParameters 17 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesMonthCurrent.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesMonthCurrent () { 2 | <# 3 | .SYNOPSIS 4 | Finds the start and end dates of the current month. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates of the current month based on the current date. 8 | 9 | .EXAMPLE 10 | Find-DatesMonthCurrent 11 | Returns the start and end dates of the current month. 12 | 13 | #> 14 | $DateMonthFirstDay = (GET-DATE -Day 1).Date 15 | $DateMonthLastDay = GET-DATE $DateMonthFirstDay.AddMonths(1).AddSeconds(-1) 16 | 17 | $DateParameters = @{ 18 | DateFrom = $DateMonthFirstDay 19 | DateTo = $DateMonthLastDay 20 | } 21 | return $DateParameters 22 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesMonthPast.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesMonthPast ([bool] $Force) { 2 | <# 3 | .SYNOPSIS 4 | Finds the dates for the previous month based on the current date. 5 | 6 | .DESCRIPTION 7 | This function calculates the date range for the previous month based on the current date. It returns the start and end dates of the previous month. 8 | 9 | .PARAMETER Force 10 | If set to $true, the function will always return the date range for the previous month, regardless of the current date. 11 | 12 | .EXAMPLE 13 | Find-DatesMonthPast -Force $false 14 | Returns $null if the current date is not the first day of the month. 15 | 16 | .EXAMPLE 17 | Find-DatesMonthPast -Force $true 18 | Returns the date range for the previous month even if the current date is not the first day of the month. 19 | #> 20 | $DateToday = (Get-Date).Date 21 | $DateMonthFirstDay = (GET-DATE -Day 1).Date 22 | $DateMonthPreviousFirstDay = $DateMonthFirstDay.AddMonths(-1) 23 | 24 | if ($Force -eq $true -or $DateToday -eq $DateMonthFirstDay) { 25 | $DateParameters = @{ 26 | DateFrom = $DateMonthPreviousFirstDay 27 | DateTo = $DateMonthFirstDay 28 | } 29 | return $DateParameters 30 | } else { 31 | return $null 32 | } 33 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesPastHour.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesPastHour () { 2 | <# 3 | .SYNOPSIS 4 | Finds the date range for the past hour. 5 | 6 | .DESCRIPTION 7 | This function calculates the date range for the past hour, starting from the beginning of the previous hour up to the current hour. 8 | 9 | .EXAMPLE 10 | Find-DatesPastHour 11 | Returns a hashtable with DateFrom and DateTo keys representing the date range for the past hour. 12 | 13 | #> 14 | $DateTodayEnd = Get-Date -Minute 0 -Second 0 -Millisecond 0 15 | $DateTodayStart = $DateTodayEnd.AddHours(-1) 16 | 17 | $DateParameters = @{ 18 | DateFrom = $DateTodayStart 19 | DateTo = $DateTodayEnd 20 | } 21 | return $DateParameters 22 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesPastWeek.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesPastWeek($DayName) { 2 | <# 3 | .SYNOPSIS 4 | Finds the date range for the past week based on the specified day. 5 | 6 | .DESCRIPTION 7 | This function calculates the date range for the past week based on the specified day of the week. 8 | 9 | .PARAMETER DayName 10 | The day of the week to use as a reference for finding the past week's date range. 11 | 12 | .EXAMPLE 13 | Find-DatesPastWeek -DayName "Monday" 14 | Returns the date range for the past week starting from the previous Monday. 15 | 16 | .EXAMPLE 17 | Find-DatesPastWeek -DayName "Friday" 18 | Returns the date range for the past week starting from the previous Friday. 19 | 20 | #> 21 | $DateTodayStart = Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0 22 | if ($DateTodayStart.DayOfWeek -ne $DayName) { 23 | return $null 24 | } 25 | $DateTodayEnd = (Get-Date -Hour 0 -Minute 0 -Second 0 -Millisecond 0).AddDays(-7) 26 | $DateParameters = @{ 27 | DateFrom = $DateTodayEnd 28 | DateTo = $DateTodayStart 29 | } 30 | return $DateParameters 31 | 32 | } -------------------------------------------------------------------------------- /Private/Deprecated/Dates/Find-DatesQuarterCurrent.ps1: -------------------------------------------------------------------------------- 1 | function Find-DatesQuarterCurrent ([bool] $Force) { 2 | <# 3 | .SYNOPSIS 4 | Finds the start and end dates of the current quarter. 5 | 6 | .DESCRIPTION 7 | This function calculates the start and end dates of the current quarter based on the current date. 8 | 9 | .PARAMETER Force 10 | If set to $true, forces the function to recalculate the dates even if they have been previously calculated. 11 | 12 | .EXAMPLE 13 | Find-DatesQuarterCurrent -Force $false 14 | Returns the start and end dates of the current quarter without recalculating if already calculated. 15 | 16 | .EXAMPLE 17 | Find-DatesQuarterCurrent -Force $true 18 | Forces the function to recalculate and returns the start and end dates of the current quarter. 19 | 20 | #> 21 | $Today = (Get-Date) 22 | $Quarter = [Math]::Ceiling($Today.Month / 3) 23 | $LastDay = [DateTime]::DaysInMonth([Int]$Today.Year.ToString(), [Int]($Quarter * 3)) 24 | $StartDate = (get-date -Year $Today.Year -Month ($Quarter * 3 - 2) -Day 1).Date 25 | $EndDate = (get-date -Year $Today.Year -Month ($Quarter * 3) -Day $LastDay).Date.AddDays(1).AddTicks(-1) 26 | $DateParameters = @{ 27 | DateFrom = $StartDate 28 | DateTo = $EndDate 29 | } 30 | return $DateParameters 31 | } -------------------------------------------------------------------------------- /Private/Deprecated/Email/Get-HTML.ps1: -------------------------------------------------------------------------------- 1 | function Get-HTML { 2 | <# 3 | .SYNOPSIS 4 | Splits the input text by carriage return and outputs each line. 5 | 6 | .DESCRIPTION 7 | This function takes a string input and splits it by carriage return (`r) to output each line separately. 8 | 9 | .PARAMETER text 10 | The input text to be split and displayed line by line. 11 | 12 | .EXAMPLE 13 | Get-HTML -text "Line 1`rLine 2`rLine 3" 14 | This example splits the input text by carriage return and outputs each line separately. 15 | 16 | #> 17 | [CmdletBinding()] 18 | param ( 19 | [string] $text 20 | ) 21 | $text = $text.Split("`r") 22 | foreach ($t in $text) { 23 | Write-Host $t 24 | } 25 | } -------------------------------------------------------------------------------- /Private/Deprecated/Email/Set-EmailBodyPreparedTable.ps1: -------------------------------------------------------------------------------- 1 | function Set-EmailBodyPreparedTable ($TableData, $TableWelcomeMessage) { 2 | <# 3 | .SYNOPSIS 4 | Prepares the email body with a welcome message and table data. 5 | 6 | .DESCRIPTION 7 | This function prepares the email body by combining a welcome message and table data into a single HTML string. 8 | 9 | .PARAMETER TableData 10 | The data to be included in the email body table. 11 | 12 | .PARAMETER TableWelcomeMessage 13 | The welcome message to be displayed at the beginning of the email body. 14 | 15 | .EXAMPLE 16 | $tableData = "
JohnDoe
" 17 | $welcomeMessage = "Welcome to our platform!" 18 | Set-EmailBodyPreparedTable -TableData $tableData -TableWelcomeMessage $welcomeMessage 19 | 20 | This example prepares the email body with a welcome message "Welcome to our platform!" and table data "
JohnDoe
". 21 | 22 | #> 23 | $body = "

$TableWelcomeMessage

" 24 | $body += $TableData 25 | return $body 26 | } -------------------------------------------------------------------------------- /Private/Deprecated/Email/Set-EmailWordReplacementsHash.ps1: -------------------------------------------------------------------------------- 1 | function Set-EmailWordReplacementsHash { 2 | <# 3 | .SYNOPSIS 4 | Replaces words in an email body based on a given hash table of substitutions. 5 | 6 | .DESCRIPTION 7 | This function replaces words in the email body with specified substitutions using a hash table. 8 | 9 | .PARAMETER Body 10 | The email body where the word replacements will be applied. 11 | 12 | .PARAMETER Substitute 13 | A hash table containing the words to be replaced as keys and their corresponding substitutions as values. 14 | 15 | .EXAMPLE 16 | $body = "Hello, my name is John." 17 | $substitutions = @{ 18 | "John" = "Jane" 19 | } 20 | Set-EmailWordReplacementsHash -Body $body -Substitute $substitutions 21 | # This will replace "John" with "Jane" in the email body. 22 | 23 | #> 24 | [CmdletBinding()] 25 | param ( 26 | $Body, 27 | $Substitute 28 | ) 29 | foreach ($Key in $Substitute.Keys) { 30 | Write-Verbose "Set-EmailWordReplacementsHash - Key: $Key Value: $($Substitute.$Key)" 31 | $Body = Set-EmailWordReplacements -Body $Body -Replace $Key -ReplaceWith $Substitute.$Key 32 | } 33 | return $Body 34 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Add-ToArray.ps1: -------------------------------------------------------------------------------- 1 | function Add-ToArray { 2 | <# 3 | .SYNOPSIS 4 | Adds an element to an ArrayList. 5 | 6 | .DESCRIPTION 7 | This function adds an element to the specified ArrayList. 8 | 9 | .PARAMETER List 10 | The ArrayList to which the element will be added. 11 | 12 | .PARAMETER Element 13 | The element to be added to the ArrayList. 14 | 15 | .EXAMPLE 16 | $myList = New-Object System.Collections.ArrayList 17 | Add-ToArray -List $myList -Element "Apple" 18 | # Adds the string "Apple" to the ArrayList $myList. 19 | 20 | .EXAMPLE 21 | $myList = New-Object System.Collections.ArrayList 22 | Add-ToArray -List $myList -Element 42 23 | # Adds the integer 42 to the ArrayList $myList. 24 | #> 25 | [CmdletBinding()] 26 | param( 27 | [System.Collections.ArrayList] $List, 28 | [Object] $Element 29 | ) 30 | #Write-Verbose "Add-ToArray - Element: $Element" 31 | [void] $List.Add($Element) #> $null 32 | } 33 | -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Add-ToHashTable.ps1: -------------------------------------------------------------------------------- 1 | function Add-ToHashTable($Hashtable, $Key, $Value) { 2 | <# 3 | .SYNOPSIS 4 | Adds a key-value pair to a hashtable. 5 | 6 | .DESCRIPTION 7 | This function adds a key-value pair to a given hashtable. If the value is not null or empty, it is added to the hashtable. 8 | 9 | .PARAMETER Hashtable 10 | The hashtable to which the key-value pair will be added. 11 | 12 | .PARAMETER Key 13 | The key of the key-value pair to be added. 14 | 15 | .PARAMETER Value 16 | The value of the key-value pair to be added. 17 | 18 | .EXAMPLE 19 | $myHashtable = @{} 20 | Add-ToHashTable -Hashtable $myHashtable -Key "Name" -Value "John" 21 | # Adds the key-value pair "Name"-"John" to $myHashtable. 22 | 23 | .EXAMPLE 24 | $myHashtable = @{} 25 | Add-ToHashTable -Hashtable $myHashtable -Key "Age" -Value 25 26 | # Adds the key-value pair "Age"-25 to $myHashtable. 27 | #> 28 | if ($null -ne $Value -and $Value -ne '') { 29 | $Hashtable.Add($Key, $Value) 30 | } 31 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Get-HashMaxValue.ps1: -------------------------------------------------------------------------------- 1 | function Get-HashMaxValue { 2 | <# 3 | .SYNOPSIS 4 | Gets the maximum value from a hashtable. 5 | 6 | .DESCRIPTION 7 | This function retrieves the maximum value from a given hashtable. It can also return the minimum value if the -Lowest switch is used. 8 | 9 | .PARAMETER hashTable 10 | The hashtable from which to find the maximum value. 11 | 12 | .PARAMETER Lowest 13 | If specified, the function will return the minimum value instead of the maximum. 14 | 15 | .EXAMPLE 16 | $myHashTable = @{ 'A' = 10; 'B' = 20; 'C' = 5 } 17 | Get-HashMaxValue -hashTable $myHashTable 18 | # Output: 20 19 | 20 | .EXAMPLE 21 | $myHashTable = @{ 'A' = 10; 'B' = 20; 'C' = 5 } 22 | Get-HashMaxValue -hashTable $myHashTable -Lowest 23 | # Output: 5 24 | #> 25 | [CmdletBinding()] 26 | param ( 27 | [Object] $hashTable, 28 | [switch] $Lowest 29 | ) 30 | if ($Lowest) { 31 | return ($hashTable.GetEnumerator() | Sort-Object value -Descending | Select-Object -Last 1).Value 32 | } else { 33 | return ($hashTable.GetEnumerator() | Sort-Object value -Descending | Select-Object -First 1).Value 34 | } 35 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Get-ObjectCount.ps1: -------------------------------------------------------------------------------- 1 | function Get-ObjectCount { 2 | <# 3 | .SYNOPSIS 4 | Counts the number of objects passed as input. 5 | 6 | .DESCRIPTION 7 | This function calculates and returns the total count of objects passed as input. It is designed to be used in scenarios where counting the number of objects is required. 8 | 9 | .PARAMETER Object 10 | Specifies the object or objects for which the count needs to be calculated. 11 | 12 | .EXAMPLE 13 | Get-Process | Get-ObjectCount 14 | Returns the total count of processes currently running. 15 | 16 | .EXAMPLE 17 | $Files = Get-ChildItem -Path "C:\Files" 18 | $FileCount = $Files | Get-ObjectCount 19 | Returns the total count of files in the specified directory. 20 | 21 | #> 22 | [CmdletBinding()] 23 | param( 24 | [parameter(ValueFromPipelineByPropertyName, ValueFromPipeline)][Object]$Object 25 | ) 26 | return $($Object | Measure-Object).Count 27 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Get-ObjectEnumValues.ps1: -------------------------------------------------------------------------------- 1 | Function Get-ObjectEnumValues { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the values of an enumeration type and returns them as a hashtable. 5 | 6 | .DESCRIPTION 7 | This function takes an enumeration type as input and retrieves all its values, storing them in a hashtable where the key is the name of the enum value and the value is the corresponding numeric value. 8 | 9 | .PARAMETER enum 10 | Specifies the enumeration type for which values need to be retrieved. 11 | 12 | .EXAMPLE 13 | Get-ObjectEnumValues -enum [System.DayOfWeek] 14 | Retrieves all values of the System.DayOfWeek enumeration and returns them as a hashtable. 15 | 16 | .EXAMPLE 17 | Get-ObjectEnumValues -enum [System.ConsoleColor] 18 | Retrieves all values of the System.ConsoleColor enumeration and returns them as a hashtable. 19 | 20 | #> 21 | param( 22 | [string]$enum 23 | ) 24 | $enumValues = @{} 25 | [enum]::getvalues([type]$enum) | 26 | ForEach-Object { 27 | $enumValues.add($_, $_.value__) 28 | } 29 | $enumValues 30 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Get-ObjectKeys.ps1: -------------------------------------------------------------------------------- 1 | function Get-ObjectKeys { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the keys of an object excluding a specified key. 5 | 6 | .DESCRIPTION 7 | This function retrieves the keys of an object while excluding a specified key. It returns an array of keys from the object. 8 | 9 | .PARAMETER Object 10 | The object from which keys need to be retrieved. 11 | 12 | .PARAMETER Ignore 13 | The key to be excluded from the result. 14 | 15 | .EXAMPLE 16 | $object = @{ 'key1' = 'value1'; 'key2' = 'value2'; 'key3' = 'value3' } 17 | Get-ObjectKeys -Object $object -Ignore 'key2' 18 | # Returns 'key1', 'key3' 19 | 20 | #> 21 | param( 22 | [object] $Object, 23 | [string] $Ignore 24 | ) 25 | $Data = $Object.Keys | Where-Object { $_ -notcontains $Ignore } 26 | return $Data 27 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/Get-ObjectTitles.ps1: -------------------------------------------------------------------------------- 1 | function Get-ObjectTitles { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the titles of properties from an object. 5 | 6 | .DESCRIPTION 7 | This function retrieves the titles of properties from an object and returns them in an ArrayList. 8 | 9 | .PARAMETER Object 10 | Specifies the object from which to retrieve property titles. 11 | 12 | .EXAMPLE 13 | $object = [PSCustomObject]@{ 14 | Name = "John Doe" 15 | Age = 30 16 | City = "New York" 17 | } 18 | Get-ObjectTitles -Object $object 19 | 20 | Description 21 | ----------- 22 | Retrieves the property titles from the $object and returns them in an ArrayList. 23 | 24 | #> 25 | [CmdletBinding()] 26 | param( 27 | $Object 28 | ) 29 | $ArrayList = New-Object System.Collections.ArrayList 30 | Write-Verbose "Get-ObjectTitles - ObjectType $($Object.GetType())" 31 | foreach ($Title in $Object.PSObject.Properties) { 32 | Write-Verbose "Get-ObjectTitles - Value added to array: $($Title.Name)" 33 | $ArrayList.Add($Title.Name) | Out-Null 34 | } 35 | Write-Verbose "Get-ObjectTitles - Array size: $($ArrayList.Count)" 36 | return $ArrayList 37 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/New-ArrayList.ps1: -------------------------------------------------------------------------------- 1 | function New-ArrayList { 2 | <# 3 | .SYNOPSIS 4 | Creates a new ArrayList object. 5 | 6 | .DESCRIPTION 7 | This function creates a new instance of the ArrayList class from the System.Collections namespace. 8 | 9 | .EXAMPLE 10 | $myList = New-ArrayList 11 | $myList.Add("Apple") 12 | $myList.Add("Banana") 13 | $myList.Add("Orange") 14 | $myList 15 | #> 16 | [CmdletBinding()] 17 | param() 18 | $List = [System.Collections.ArrayList]::new() 19 | <# 20 | Mathias R�rbo Jessen: 21 | The pipeline will attempt to unravel the list on assignment, 22 | so you'll have to either wrap the empty arraylist in an array, 23 | like above, or call WriteObject explicitly and tell it not to, like so: 24 | $PSCmdlet.WriteObject($List,$false) 25 | #> 26 | return , $List 27 | } -------------------------------------------------------------------------------- /Private/Deprecated/Objects/New-GenericList.ps1: -------------------------------------------------------------------------------- 1 | function New-GenericList { 2 | <# 3 | .SYNOPSIS 4 | Creates a new instance of a generic list. 5 | 6 | .DESCRIPTION 7 | This function creates a new instance of a generic list based on the specified type. 8 | 9 | .PARAMETER Type 10 | Specifies the type of objects that the generic list will hold. Defaults to [System.Object]. 11 | 12 | .EXAMPLE 13 | PS C:\> $list = New-GenericList -Type [int] 14 | Creates a new generic list that holds integers. 15 | 16 | .EXAMPLE 17 | PS C:\> $list = New-GenericList 18 | Creates a new generic list that holds objects. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | [Object] $Type = [System.Object] 24 | ) 25 | return New-Object "System.Collections.Generic.List[$Type]" 26 | } -------------------------------------------------------------------------------- /Private/Get-IPRange.ps1: -------------------------------------------------------------------------------- 1 | function Get-IPRange { 2 | <# 3 | .SYNOPSIS 4 | Generates a list of IP addresses within a specified binary range. 5 | 6 | .DESCRIPTION 7 | This function takes two binary strings representing the start and end IP addresses and generates a list of IP addresses within that range. 8 | 9 | .PARAMETER StartBinary 10 | Specifies the starting IP address in binary format. 11 | 12 | .PARAMETER EndBinary 13 | Specifies the ending IP address in binary format. 14 | 15 | .EXAMPLE 16 | Get-IPRange -StartBinary '11000000' -EndBinary '11000010' 17 | Description: 18 | Generates a list of IP addresses between '192.0.0.0' and '192.0.2.0'. 19 | 20 | .EXAMPLE 21 | Get-IPRange -StartBinary '10101010' -EndBinary '10101100' 22 | Description: 23 | Generates a list of IP addresses between '170.0.0.0' and '172.0.0.0'. 24 | #> 25 | [cmdletBinding()] 26 | param( 27 | [string] $StartBinary, 28 | [string] $EndBinary 29 | ) 30 | [int64] $StartInt = [System.Convert]::ToInt64($StartBinary, 2) 31 | [int64] $EndInt = [System.Convert]::ToInt64($EndBinary, 2) 32 | for ($BinaryIP = $StartInt; $BinaryIP -le $EndInt; $BinaryIP++) { 33 | Convert-BinaryToIP ([System.Convert]::ToString($BinaryIP, 2).PadLeft(32, '0')) 34 | } 35 | } -------------------------------------------------------------------------------- /Private/Get-LocalComputerSid.ps1: -------------------------------------------------------------------------------- 1 | function Get-LocalComputerSid { 2 | <# 3 | .SYNOPSIS 4 | Get the SID of the local computer. 5 | 6 | .DESCRIPTION 7 | Get the SID of the local computer. 8 | 9 | .EXAMPLE 10 | Get-LocalComputerSid 11 | 12 | .NOTES 13 | General notes 14 | #> 15 | [cmdletBinding()] 16 | param() 17 | try { 18 | Add-Type -AssemblyName System.DirectoryServices.AccountManagement 19 | $PrincipalContext = [System.DirectoryServices.AccountManagement.PrincipalContext]::new([System.DirectoryServices.AccountManagement.ContextType]::Machine) 20 | $UserPrincipal = [System.DirectoryServices.AccountManagement.UserPrincipal]::new($PrincipalContext) 21 | $Searcher = [System.DirectoryServices.AccountManagement.PrincipalSearcher]::new() 22 | $Searcher.QueryFilter = $UserPrincipal 23 | $User = $Searcher.FindAll() 24 | foreach ($U in $User) { 25 | if ($U.Sid.Value -like "*-500") { 26 | return $U.Sid.Value.TrimEnd("-500") 27 | } 28 | } 29 | } catch { 30 | Write-Warning -Message "Get-LocalComputerSid - Error: $($_.Exception.Message)" 31 | } 32 | } -------------------------------------------------------------------------------- /Private/Test-IPIsInNetwork.ps1: -------------------------------------------------------------------------------- 1 | function Test-IPIsInNetwork { 2 | <# 3 | .SYNOPSIS 4 | Checks if an IP address falls within a specified range defined by binary start and end values. 5 | 6 | .DESCRIPTION 7 | This function compares the binary representation of an IP address with the binary start and end values to determine if the IP address falls within the specified range. 8 | 9 | .EXAMPLE 10 | Test-IPIsInNetwork -IP "192.168.1.10" -StartBinary "11000000101010000000000100000000" -EndBinary "11000000101010000000000111111111" 11 | 12 | Description: 13 | Checks if the IP address 192.168.1.10 falls within the range defined by the binary start and end values. 14 | 15 | #> 16 | [cmdletBinding()] 17 | param( 18 | [string] $IP, 19 | [string] $StartBinary, 20 | [string] $EndBinary 21 | ) 22 | $TestIPBinary = Convert-IPToBinary $IP 23 | [int64] $TestIPInt64 = [System.Convert]::ToInt64($TestIPBinary, 2) 24 | [int64] $StartInt64 = [System.Convert]::ToInt64($StartBinary, 2) 25 | [int64] $EndInt64 = [System.Convert]::ToInt64($EndBinary, 2) 26 | if ($TestIPInt64 -ge $StartInt64 -and $TestIPInt64 -le $EndInt64) { 27 | return $True 28 | } else { 29 | return $False 30 | } 31 | } -------------------------------------------------------------------------------- /Private/Unregister-MountedRegistry.ps1: -------------------------------------------------------------------------------- 1 | function Unregister-MountedRegistry { 2 | <# 3 | .SYNOPSIS 4 | Unregisters mounted registry paths. 5 | 6 | .DESCRIPTION 7 | This function unregisters mounted registry paths that were previously mounted using Mount-PSRegistryPath. 8 | 9 | .EXAMPLE 10 | Unregister-MountedRegistry 11 | 12 | Description: 13 | Unregisters all mounted registry paths. 14 | 15 | #> 16 | [CmdletBinding()] 17 | param( 18 | 19 | ) 20 | if ($null -ne $Script:DefaultRegistryMounted) { 21 | Write-Verbose -Message "Unregister-MountedRegistry - Dismounting HKEY_USERS\.DEFAULT_USER" 22 | $null = Dismount-PSRegistryPath -MountPoint "HKEY_USERS\.DEFAULT_USER" 23 | $Script:DefaultRegistryMounted = $null 24 | } 25 | if ($null -ne $Script:OfflineRegistryMounted) { 26 | foreach ($Key in $Script:OfflineRegistryMounted.Keys) { 27 | if ($Script:OfflineRegistryMounted[$Key].Status -eq $true) { 28 | Write-Verbose -Message "Unregister-MountedRegistry - Dismounting HKEY_USERS\$Key" 29 | $null = Dismount-PSRegistryPath -MountPoint "HKEY_USERS\$Key" 30 | } 31 | } 32 | $Script:OfflineRegistryMounted = $null 33 | } 34 | } -------------------------------------------------------------------------------- /Public/Computers/Get-ComputerCulture.ps1: -------------------------------------------------------------------------------- 1 | function Get-ComputerCulture { 2 | <# 3 | .SYNOPSIS 4 | Retrieves culture information from a specified computer. 5 | 6 | .DESCRIPTION 7 | This function retrieves culture information from the specified computer. It provides details such as KeyboardLayoutId, DisplayName, and Windows Language. 8 | 9 | .PARAMETER ComputerName 10 | Specifies the name of the computer from which to retrieve culture information. Defaults to the local computer. 11 | 12 | .EXAMPLE 13 | Get-ComputerCulture 14 | Retrieves culture information from the local computer. 15 | 16 | .EXAMPLE 17 | Get-ComputerCulture -ComputerName "Server01" 18 | Retrieves culture information from a remote computer named Server01. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | [string] $ComputerName = $Env:COMPUTERNAME 24 | ) 25 | $ScriptBlock = { 26 | Get-Culture | Select-Object KeyboardLayoutId, DisplayName, @{Expression = { $_.ThreeLetterWindowsLanguageName }; Label = "Windows Language" } 27 | } 28 | if ($ComputerName -eq $Env:COMPUTERNAME) { 29 | $Data8 = Invoke-Command -ScriptBlock $ScriptBlock 30 | } else { 31 | $Data8 = Invoke-Command -ComputerName $ComputerName -ScriptBlock $ScriptBlock 32 | } 33 | return $Data8 34 | } -------------------------------------------------------------------------------- /Public/Computers/Get-ComputerMissingDrivers.ps1: -------------------------------------------------------------------------------- 1 | function Get-ComputerMissingDrivers { 2 | <# 3 | .SYNOPSIS 4 | Retrieves information about missing drivers on a specified computer. 5 | 6 | .DESCRIPTION 7 | This function retrieves information about missing drivers on a specified computer by querying the Win32_PNPEntity WMI class. 8 | 9 | .PARAMETER ComputerName 10 | Specifies the name of the computer to query. Defaults to the local computer. 11 | 12 | .EXAMPLE 13 | Get-ComputerMissingDrivers -ComputerName "Computer01" 14 | Retrieves information about missing drivers on a computer named "Computer01". 15 | 16 | .EXAMPLE 17 | Get-ComputerMissingDrivers 18 | Retrieves information about missing drivers on the local computer. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | [string] $ComputerName = $Env:COMPUTERNAME 24 | ) 25 | $Data = Get-WmiObject Win32_PNPEntity -ComputerName $ComputerName | Where-Object {$_.Configmanagererrorcode -ne 0} | Select-Object Caption, ConfigmanagererrorCode, Description, DeviceId, HardwareId, PNPDeviceID 26 | return $Data 27 | } 28 | -------------------------------------------------------------------------------- /Public/Computers/Get-ComputerOEMInformation.ps1: -------------------------------------------------------------------------------- 1 | function Get-ComputerOemInformation { 2 | <# 3 | .SYNOPSIS 4 | Retrieves OEM information from a specified computer. 5 | 6 | .DESCRIPTION 7 | This function retrieves OEM information such as Model, Manufacturer, Logo, Support Phone, Support URL, and Support Hours from the specified computer. 8 | 9 | .PARAMETER ComputerName 10 | Specifies the name of the computer from which to retrieve the OEM information. If not specified, the local computer name is used. 11 | 12 | .EXAMPLE 13 | Get-ComputerOemInformation 14 | Retrieves OEM information from the local computer. 15 | 16 | .EXAMPLE 17 | Get-ComputerOemInformation -ComputerName "Computer01" 18 | Retrieves OEM information from a remote computer named "Computer01". 19 | 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | [string] $ComputerName = $Env:COMPUTERNAME 24 | ) 25 | $ScriptBlock = { Get-ItemProperty HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\OEMInformation | Select-Object Model, Manufacturer, Logo, SupportPhone, SupportURL, SupportHours } 26 | if ($ComputerName -eq $Env:COMPUTERNAME) { 27 | $Data = Invoke-Command -ScriptBlock $ScriptBlock 28 | } else { 29 | $Data = Invoke-Command -ComputerName $ComputerName -ScriptBlock $ScriptBlock 30 | } 31 | return $Data 32 | } -------------------------------------------------------------------------------- /Public/Computers/Get-ComputerServices.ps1: -------------------------------------------------------------------------------- 1 | function Get-ComputerService { 2 | <# 3 | .SYNOPSIS 4 | Retrieves information about services running on specified computers. 5 | 6 | .DESCRIPTION 7 | This function retrieves information about services running on one or more specified computers. It returns details such as ComputerName, Name, Displayname, Status, and StartType of the services. 8 | 9 | .EXAMPLE 10 | Get-ComputerServices -ComputerName "Computer01" 11 | Retrieves information about services running on a single computer named "Computer01". 12 | 13 | .EXAMPLE 14 | Get-ComputerServices -ComputerName "Computer01", "Computer02" 15 | Retrieves information about services running on multiple computers named "Computer01" and "Computer02". 16 | 17 | #> 18 | [alias('Get-ComputerServices')] 19 | [CmdletBinding()] 20 | param( 21 | [string[]] $ComputerName = $Env:COMPUTERNAME 22 | ) 23 | Process { 24 | foreach ($Computer in $ComputerName) { 25 | $Services = Get-PSService -ComputerName $Computer | Select-Object ComputerName, Name, Displayname, Status, StartType 26 | $Services 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /Public/Connectivity/Get-IPAddressInformation.ps1: -------------------------------------------------------------------------------- 1 | function Get-IPAddressInformation { 2 | <# 3 | .SYNOPSIS 4 | Retrieves detailed information about an IP address using the ip-api.com service. 5 | 6 | .DESCRIPTION 7 | This function retrieves detailed information about the specified IP address using the ip-api.com service. It provides details such as country, region, city, ISP, and more. 8 | 9 | .PARAMETER IP 10 | Specifies the IP address for which information needs to be retrieved. 11 | 12 | .EXAMPLE 13 | Get-IpAddressInformation -IP "8.8.8.8" 14 | Retrieves information about the IP address "8.8.8.8" using the ip-api.com service. 15 | 16 | .NOTES 17 | This function requires an active internet connection to retrieve IP address information from the ip-api.com service. 18 | #> 19 | [cmdletbinding()] 20 | param( 21 | [string] $IP 22 | ) 23 | try { 24 | $Information = Invoke-RestMethod -Method get -Uri "http://ip-api.com/json/$ip" 25 | } catch { 26 | $ErrorMessage = $_.Exception.Message -replace "`n", " " -replace "`r", " " 27 | Write-Warning "Get-IPAddressInformation - Error occured on IP $IP`: $ErrorMessage" 28 | } 29 | return $Information 30 | } -------------------------------------------------------------------------------- /Public/Connectivity/Get-MyIpAddress.ps1: -------------------------------------------------------------------------------- 1 | function Get-MyIpAddress { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the public IP address of the current machine using OpenDNS. 5 | 6 | .DESCRIPTION 7 | This function retrieves the public IP address of the current machine by querying OpenDNS servers. It returns the IP address as a string. 8 | 9 | .EXAMPLE 10 | Get-MyIpAddress 11 | Retrieves the public IP address of the current machine. 12 | 13 | .NOTES 14 | Author: Your Name 15 | Date: Current Date 16 | #> 17 | [alias('Get-MyIP')] 18 | [CmdletBinding()] 19 | param() 20 | $DNSParam = @{ 21 | Name = 'myip.opendns.com' 22 | Server = 'resolver1.opendns.com' 23 | DnsOnly = $true 24 | } 25 | return Resolve-DnsName @DNSParam | ForEach-Object IPAddress 26 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-BinaryToHex.ps1: -------------------------------------------------------------------------------- 1 | function Convert-BinaryToHex { 2 | <# 3 | .SYNOPSIS 4 | Converts an array of binary numbers to hexadecimal format. 5 | 6 | .DESCRIPTION 7 | This function takes an array of binary numbers and converts them to hexadecimal format. 8 | 9 | .PARAMETER Binary 10 | Specifies the array of binary numbers to be converted to hexadecimal. 11 | 12 | .EXAMPLE 13 | Convert-BinaryToHex -Binary 1101 1010 14 | Converts the binary numbers 1101 and 1010 to hexadecimal format. 15 | 16 | .EXAMPLE 17 | 1101 1010 | Convert-BinaryToHex 18 | Converts the binary numbers 1101 and 1010 piped into the function to hexadecimal format. 19 | #> 20 | param( 21 | [alias('Bin')] 22 | [Parameter(Position = 0, Mandatory = $false, ValueFromPipeline = $true)] 23 | [Byte[]]$Binary 24 | ) 25 | if ($null -eq $Binary) { 26 | return 27 | } 28 | # assume pipeline input if we don't have an array (surely there must be a better way) 29 | if ($Binary.Length -eq 1) { 30 | $Binary = @($input) 31 | } 32 | $Return = -join ($Binary | ForEach-Object { "{0:X2}" -f $_ }) 33 | $Return 34 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-BinaryToString.ps1: -------------------------------------------------------------------------------- 1 | function Convert-BinaryToString { 2 | <# 3 | .SYNOPSIS 4 | Converts an array of binary numbers to a string. 5 | 6 | .DESCRIPTION 7 | This function takes an array of binary numbers and converts them to a string using Unicode encoding. 8 | 9 | .PARAMETER Binary 10 | Specifies the array of binary numbers to be converted to a string. 11 | 12 | .EXAMPLE 13 | Convert-BinaryToString -Binary 01001000 01100101 01101100 01101100 01101111 14 | Converts the binary numbers to the string "Hello". 15 | 16 | .EXAMPLE 17 | 01001000 01100101 01101100 01101100 01101111 | Convert-BinaryToString 18 | Converts the binary numbers piped into the function to the string "Hello". 19 | #> 20 | param( 21 | [alias('Bin')] 22 | [Parameter(Position = 0, Mandatory = $false, ValueFromPipeline = $true)] 23 | [Byte[]]$Binary 24 | ) 25 | if ($null -ne $Binary) { 26 | [System.Text.Encoding]::Unicode.GetString($Binary) 27 | } 28 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-DomainToSid.ps1: -------------------------------------------------------------------------------- 1 | function Convert-DomainToSid { 2 | <# 3 | .SYNOPSIS 4 | Converts Domain Name to SID 5 | 6 | .DESCRIPTION 7 | Converts Domain Name to SID 8 | 9 | .PARAMETER DomainName 10 | DomainName for current forest or trusted forest 11 | 12 | .EXAMPLE 13 | Convert-DomainToSid -DomainName 'test.evotec.pl' 14 | 15 | .NOTES 16 | General notes 17 | #> 18 | [cmdletBinding()] 19 | param( 20 | [parameter(Mandatory)][string] $DomainName 21 | ) 22 | try { 23 | $BinarySID = ([ADSI]"LDAP://$DomainName").objectsid 24 | $DomainSidValue = [System.Security.Principal.SecurityIdentifier]::new($BinarySID.Value, 0).Value 25 | $DomainSidValue 26 | } catch { 27 | Write-Warning -Message "Convert-DomainToSid - Failed conversion with error $($_.Exception.Message)" 28 | } 29 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-ExchangeItems.ps1: -------------------------------------------------------------------------------- 1 | function Convert-ExchangeItems { 2 | <# 3 | .SYNOPSIS 4 | Converts the count of Exchange items to a specified default value if the count is null. 5 | 6 | .DESCRIPTION 7 | This function takes the count of Exchange items and returns the count if it is not null. If the count is null, it returns the specified default value. 8 | 9 | .PARAMETER Count 10 | The count of Exchange items to be processed. 11 | 12 | .PARAMETER Default 13 | The default value to return if the count is null. Default is 'N/A'. 14 | 15 | .EXAMPLE 16 | Convert-ExchangeItems -Count 10 -Default 'No items' 17 | # Returns 10 18 | 19 | .EXAMPLE 20 | Convert-ExchangeItems -Count $null -Default 'No items' 21 | # Returns 'No items' 22 | 23 | .NOTES 24 | General notes 25 | #> 26 | [cmdletbinding()] 27 | param( 28 | [int] $Count, 29 | [string] $Default = 'N/A' 30 | ) 31 | if ($null -eq $Count) { 32 | return $Default 33 | } else { 34 | return $Count 35 | } 36 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-HexToBinary.ps1: -------------------------------------------------------------------------------- 1 | function Convert-HexToBinary { 2 | <# 3 | .SYNOPSIS 4 | Converts a hexadecimal string to a binary representation. 5 | 6 | .DESCRIPTION 7 | This function takes a hexadecimal string as input and converts it to a binary representation. 8 | 9 | .PARAMETER Hex 10 | Specifies the hexadecimal string to convert to binary. 11 | 12 | .EXAMPLE 13 | Convert-HexToBinary -Hex "1A" 14 | # Outputs: 00011010 15 | 16 | .EXAMPLE 17 | "1A" | Convert-HexToBinary 18 | # Outputs: 00011010 19 | #> 20 | [CmdletBinding()] 21 | param( 22 | [Parameter(Position = 0, Mandatory = $true, ValueFromPipeline = $true)] [string] $Hex 23 | ) 24 | $return = for ($i = 0; $i -lt $Hex.Length ; $i += 2) { 25 | [Byte]::Parse($Hex.Substring($i, 2), [System.Globalization.NumberStyles]::HexNumber) 26 | } 27 | Write-Output $return -NoEnumerate 28 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-IPAddressToPTR.ps1: -------------------------------------------------------------------------------- 1 | function Convert-IpAddressToPtr { 2 | <# 3 | .SYNOPSIS 4 | Converts an IP address to a PTR record 5 | 6 | .DESCRIPTION 7 | This function takes an IP address as input and converts it to a PTR record. 8 | 9 | .PARAMETER IPAddress 10 | The IP address to convert 11 | 12 | .PARAMETER AsObject 13 | Should the function return an object instead of a string? 14 | 15 | .EXAMPLE 16 | Convert-IpAddressToPtr -IPAddress "10.1.2.3" 17 | 18 | .EXAMPLE 19 | Convert-IpAddressToPtr -IPAddress "10.1.2.3", "8.8.8.8" -AsObject 20 | 21 | .NOTES 22 | General notes 23 | #> 24 | [CmdletBinding()] 25 | param ( 26 | [Parameter(Mandatory = $true)] 27 | [string[]]$IPAddress, 28 | [switch] $AsObject 29 | ) 30 | foreach ($IP in $IPAddress) { 31 | 32 | # Split the IP address into its octets 33 | $octets = $IP -split "\." 34 | 35 | # Reverse the octets 36 | [array]::Reverse($octets) 37 | 38 | # Join the reversed octets with dots and append the standard PTR suffix 39 | $ptrString = ($octets -join ".") + ".in-addr.arpa" 40 | 41 | if ($AsObject) { 42 | [pscustomobject] @{ 43 | IPAddress = $IP 44 | PTR = $ptrString 45 | } 46 | } else { 47 | $ptrString 48 | } 49 | } 50 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-KeyToValue.ps1: -------------------------------------------------------------------------------- 1 | function Convert-KeyToKeyValue { 2 | <# 3 | .SYNOPSIS 4 | Converts keys of an object to key-value pairs. 5 | 6 | .DESCRIPTION 7 | This function takes an object and converts its keys to key-value pairs, where the key is the original key concatenated with its corresponding value. 8 | 9 | .PARAMETER Object 10 | Specifies the object whose keys are to be converted to key-value pairs. 11 | 12 | .EXAMPLE 13 | $Object = @{ 14 | Key1 = 'Value1' 15 | Key2 = 'Value2' 16 | } 17 | Convert-KeyToKeyValue -Object $Object 18 | # Returns a new hash table with keys as 'Key1 (Value1)' and 'Key2 (Value2)'. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param ( 23 | [object] $Object 24 | ) 25 | $NewHash = [ordered] @{} 26 | foreach ($O in $Object.Keys) { 27 | $KeyName = "$O ($($Object.$O))" 28 | $KeyValue = $Object.$O 29 | $NewHash.$KeyName = $KeyValue 30 | } 31 | return $NewHash 32 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-ToDateTime.ps1: -------------------------------------------------------------------------------- 1 | function Convert-ToDateTime { 2 | <# 3 | .SYNOPSIS 4 | Converts a file time string to a DateTime object. 5 | 6 | .DESCRIPTION 7 | This function converts a file time string to a DateTime object. It handles the conversion and provides flexibility to ignore specific file time strings. 8 | 9 | .PARAMETER Timestring 10 | Specifies the file time string to convert to a DateTime object. 11 | 12 | .PARAMETER Ignore 13 | Specifies a pattern to ignore specific file time strings. Default is '*1601*'. 14 | 15 | .EXAMPLE 16 | Convert-ToDateTime -Timestring '132479040000000000' 17 | # Converts the file time string '132479040000000000' to a DateTime object. 18 | 19 | .EXAMPLE 20 | Convert-ToDateTime -Timestring '132479040000000000' -Ignore '*1601*' 21 | # Converts the file time string '132479040000000000' to a DateTime object, ignoring any file time strings containing '1601'. 22 | 23 | #> 24 | [CmdletBinding()] 25 | param ( 26 | [string] $Timestring, 27 | [string] $Ignore = '*1601*' 28 | ) 29 | Try { 30 | $DateTime = ([datetime]::FromFileTime($Timestring)) 31 | } catch { 32 | $DateTime = $null 33 | } 34 | if ($null -eq $DateTime -or $Timestring -like $Ignore) { 35 | return $null 36 | } else { 37 | return $DateTime 38 | } 39 | } -------------------------------------------------------------------------------- /Public/Converts/Convert-ToTimeSpan.ps1: -------------------------------------------------------------------------------- 1 | function Convert-ToTimeSpan { 2 | <# 3 | .SYNOPSIS 4 | Calculates the time span between two given DateTime values. 5 | 6 | .DESCRIPTION 7 | This function calculates the time span between two specified DateTime values. It takes a start time and an end time as input parameters and returns the TimeSpan object representing the duration between them. 8 | 9 | .PARAMETER StartTime 10 | Specifies the start DateTime value. If not provided, the current date and time will be used as the default. 11 | 12 | .PARAMETER EndTime 13 | Specifies the end DateTime value. 14 | 15 | .EXAMPLE 16 | Convert-ToTimeSpan -StartTime (Get-Date).AddDays(-5) -EndTime (Get-Date) 17 | # Calculates the time span between 5 days ago and today. 18 | 19 | .EXAMPLE 20 | Convert-ToTimeSpan -StartTime '2022-01-01' -EndTime '2022-01-10' 21 | # Calculates the time span between January 1, 2022, and January 10, 2022. 22 | 23 | #> 24 | [CmdletBinding()] 25 | param ( 26 | [DateTime] $StartTime = (Get-Date), 27 | [DateTime] $EndTime 28 | ) 29 | if ($StartTime -and $EndTime) { 30 | try { 31 | $TimeSpan = (New-TimeSpan -Start $StartTime -End $EndTime) 32 | } catch { 33 | $TimeSpan = $null 34 | } 35 | } 36 | if ($null -ne $TimeSpan) { 37 | return $TimeSpan 38 | } else { 39 | return $null 40 | } 41 | } -------------------------------------------------------------------------------- /Public/Converts/ConvertFrom-OperationType.ps1: -------------------------------------------------------------------------------- 1 | Function ConvertFrom-OperationType { 2 | <# 3 | .SYNOPSIS 4 | Converts operation type codes to human-readable descriptions. 5 | 6 | .DESCRIPTION 7 | This function takes an operation type code and returns the corresponding human-readable description. 8 | 9 | .PARAMETER OperationType 10 | The operation type code to be converted. 11 | 12 | .EXAMPLE 13 | ConvertFrom-OperationType -OperationType '%%14674' 14 | Output: 'Value Added' 15 | 16 | .EXAMPLE 17 | ConvertFrom-OperationType -OperationType '%%14675' 18 | Output: 'Value Deleted' 19 | 20 | .EXAMPLE 21 | ConvertFrom-OperationType -OperationType '%%14676' 22 | Output: 'Unknown' 23 | #> 24 | param ( 25 | [string] $OperationType 26 | ) 27 | $Known = @{ 28 | '%%14674' = 'Value Added' 29 | '%%14675' = 'Value Deleted' 30 | '%%14676' = 'Unknown' 31 | } 32 | foreach ($id in $OperationType) { 33 | if ($name = $Known[$id]) { return $name } 34 | } 35 | return $OperationType 36 | } -------------------------------------------------------------------------------- /Public/Converts/ConvertFrom-ScriptBlock.ps1: -------------------------------------------------------------------------------- 1 | function ConvertFrom-ScriptBlock { 2 | <# 3 | .SYNOPSIS 4 | Converts a ScriptBlock into an array of strings, each representing a line of the script block. 5 | 6 | .DESCRIPTION 7 | This function takes a ScriptBlock as input and converts it into an array of strings, where each string represents a line of the script block. 8 | 9 | .PARAMETER ScriptBlock 10 | The ScriptBlock to be converted into an array of strings. 11 | 12 | .EXAMPLE 13 | ConvertFrom-ScriptBlock -ScriptBlock { 14 | $Variable1 = "Value1" 15 | $Variable2 = "Value2" 16 | Write-Host "Hello, World!" 17 | } 18 | 19 | This example will output an array containing the following strings: 20 | $Variable1 = "Value1" 21 | $Variable2 = "Value2" 22 | Write-Host "Hello, World!" 23 | 24 | .NOTES 25 | General notes 26 | #> 27 | [CmdletBinding()] 28 | param( 29 | [ScriptBlock] $ScriptBlock 30 | ) 31 | [Array] $Output = foreach ($Line in $ScriptBlock.Ast.EndBlock.Statements.Extent) { 32 | [string] $Line + [System.Environment]::NewLine 33 | } 34 | return $Output 35 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Get-FileInformation.ps1: -------------------------------------------------------------------------------- 1 | function Get-FileInformation { 2 | <# 3 | .SYNOPSIS 4 | Get information about file such as Name, FullName and Size 5 | 6 | .DESCRIPTION 7 | Get information about file such as Name, FullName and Size 8 | 9 | .PARAMETER File 10 | File to get information about 11 | 12 | .EXAMPLE 13 | Get-FileInformation -File 'C:\Support\GitHub\PSSharedGoods\Public\FilesFolders\Get-FileInformation.ps1' 14 | 15 | #> 16 | [CmdletBinding()] 17 | param( 18 | [alias('LiteralPath', 'Path')][string] $File 19 | ) 20 | if (Test-Path -LiteralPath $File) { 21 | $Item = Get-Item -LiteralPath $File 22 | [PSCustomObject] @{ 23 | Name = $Item.Name 24 | FullName = $Item.FullName 25 | Size = Get-FileSize -Bytes $Item.Length 26 | IsReadOnly = $Item.IsReadOnly 27 | LastWriteTime = $Item.LastWriteTime 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Get-FileSize.ps1: -------------------------------------------------------------------------------- 1 | function Get-FileSize { 2 | <# 3 | .SYNOPSIS 4 | Get-FileSize function calculates the file size in human-readable format. 5 | 6 | .DESCRIPTION 7 | This function takes a file size in bytes and converts it into a human-readable format (e.g., KB, MB, GB, etc.). 8 | 9 | .PARAMETER Bytes 10 | Specifies the size of the file in bytes. 11 | 12 | .EXAMPLE 13 | Get-FileSize -Bytes 1024 14 | Output: 1 KB 15 | 16 | .EXAMPLE 17 | Get-FileSize -Bytes 1048576 18 | Output: 1 MB 19 | #> 20 | [CmdletBinding()] 21 | param( 22 | $Bytes 23 | ) 24 | $sizes = 'Bytes,KB,MB,GB,TB,PB,EB,ZB' -split ',' 25 | for ($i = 0; ($Bytes -ge 1kb) -and ($i -lt $sizes.Count); $i++) { 26 | $Bytes /= 1kb 27 | } 28 | $N = 2; 29 | if ($i -eq 0) { 30 | $N = 0 31 | } 32 | return "{0:N$($N)} {1}" -f $Bytes, $sizes[$i] 33 | } 34 | -------------------------------------------------------------------------------- /Public/FilesFolders/Get-FilesInFolder.ps1: -------------------------------------------------------------------------------- 1 | function Get-FilesInFolder { 2 | <# 3 | .SYNOPSIS 4 | Retrieves a list of files in a specified folder with the option to filter by extension. 5 | 6 | .DESCRIPTION 7 | This function retrieves a list of files in the specified folder. By default, it includes all files with the '.evtx' extension, but you can specify a different extension using the $Extension parameter. 8 | 9 | .PARAMETER Folder 10 | Specifies the folder path from which to retrieve files. 11 | 12 | .PARAMETER Extension 13 | Specifies the file extension to filter by. Default value is '*.evtx'. 14 | 15 | .EXAMPLE 16 | Get-FilesInFolder -Folder "C:\Logs" 17 | 18 | Description: 19 | Retrieves all files with the '.evtx' extension in the "C:\Logs" folder. 20 | 21 | .EXAMPLE 22 | Get-FilesInFolder -Folder "D:\Documents" -Extension '*.txt' 23 | 24 | Description: 25 | Retrieves all files with the '.txt' extension in the "D:\Documents" folder. 26 | 27 | #> 28 | [CmdletBinding()] 29 | param( 30 | [string] $Folder, 31 | [string] $Extension = '*.evtx' 32 | ) 33 | 34 | $Files = Get-ChildItem -Path $Folder -Filter $Extension -Recurse 35 | $ReturnFiles = foreach ($File in $Files) { 36 | $File.FullName 37 | } 38 | return $ReturnFiles 39 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Get-PathSeparator.ps1: -------------------------------------------------------------------------------- 1 | function Get-PathSeparator { 2 | <# 3 | .SYNOPSIS 4 | Gets the path separator character used by the operating system. 5 | 6 | .DESCRIPTION 7 | This function retrieves the path separator character used by the operating system. It can be useful for handling file paths in a platform-independent manner. 8 | 9 | .EXAMPLE 10 | Get-PathSeparator 11 | Output: 12 | \ 13 | 14 | .NOTES 15 | The function uses [System.IO.Path]::PathSeparator to get the path separator character. 16 | #> 17 | [CmdletBinding()] 18 | param() 19 | return [IO.Path]::PathSeparator 20 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Get-PathTemporary.ps1: -------------------------------------------------------------------------------- 1 | function Get-PathTemporary { 2 | <# 3 | .SYNOPSIS 4 | Gets the path to the temporary directory. 5 | 6 | .DESCRIPTION 7 | This function retrieves the path to the system's temporary directory. 8 | 9 | .EXAMPLE 10 | Get-PathTemporary 11 | Output: 12 | C:\Users\Username\AppData\Local\Temp 13 | 14 | .NOTES 15 | The function uses [System.IO.Path]::GetTempPath() to get the temporary directory path. 16 | #> 17 | [CmdletBinding()] 18 | param() 19 | return [IO.path]::GetTempPath() 20 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Get-TemporaryDirectory.ps1: -------------------------------------------------------------------------------- 1 | function Get-TemporaryDirectory { 2 | <# 3 | .SYNOPSIS 4 | Creates a temporary directory and returns its path. 5 | 6 | .DESCRIPTION 7 | This function generates a temporary directory with a unique name and returns the full path to the directory. 8 | 9 | .EXAMPLE 10 | $tempDir = Get-TemporaryDirectory 11 | $tempDir 12 | Output: 13 | C:\Users\Username\AppData\Local\Temp\abcde12345 14 | 15 | .NOTES 16 | The temporary directory is created using a random string name with specified characteristics. 17 | #> 18 | param( 19 | 20 | ) 21 | $TemporaryFolder = Get-RandomStringName -Size 13 -LettersOnly -ToLower 22 | $TemporaryPath = [system.io.path]::GetTempPath() 23 | $Output = New-Item -ItemType Directory -Path $TemporaryPath -Name $TemporaryFolder -Force 24 | if (Test-Path -LiteralPath $Output.FullName) { 25 | $Output 26 | } 27 | } -------------------------------------------------------------------------------- /Public/FilesFolders/Set-FileInheritance.ps1: -------------------------------------------------------------------------------- 1 | function Set-FileInheritance { 2 | <# 3 | .SYNOPSIS 4 | Sets or removes inheritance for a specified directory. 5 | 6 | .DESCRIPTION 7 | This function allows you to set or remove inheritance for a specified directory. You can choose to disable inheritance and optionally keep the inherited ACL. 8 | 9 | .PARAMETER StartingDir 10 | Specifies the directory for which to set or remove inheritance. 11 | 12 | .PARAMETER DisableInheritance 13 | Switch parameter to disable inheritance for the specified directory. 14 | 15 | .PARAMETER KeepInheritedAcl 16 | Switch parameter to keep the inherited ACL when disabling inheritance. 17 | 18 | .EXAMPLE 19 | Set-FileInheritance -StartingDir "C:\Example" -DisableInheritance 20 | Disables inheritance for the directory "C:\Example". 21 | 22 | .EXAMPLE 23 | Set-FileInheritance -StartingDir "D:\Data" -DisableInheritance -KeepInheritedAcl 24 | Disables inheritance for the directory "D:\Data" and keeps the inherited ACL. 25 | 26 | #> 27 | [cmdletBinding()] 28 | param( 29 | [string] $StartingDir, 30 | [switch] $DisableInheritance, 31 | [switch] $KeepInheritedAcl 32 | ) 33 | $acl = Get-Acl -Path $StartingDir 34 | $acl.SetAccessRuleProtection($DisableInheritance, $KeepInheritedAcl) 35 | $acl | Set-Acl -Path $StartingDir 36 | } -------------------------------------------------------------------------------- /Public/Objects/Copy-Dictionary.ps1: -------------------------------------------------------------------------------- 1 | function Copy-Dictionary { 2 | <# 3 | .SYNOPSIS 4 | Copies dictionary/hashtable 5 | 6 | .DESCRIPTION 7 | Copies dictionary uusing PS Serializer. Replaces usage of BinnaryFormatter due to no support in PS 7.4 8 | 9 | .PARAMETER Dictionary 10 | Dictionary to copy 11 | 12 | .EXAMPLE 13 | $Test = [ordered] @{ 14 | Test = 'Test' 15 | Test1 = @{ 16 | Test2 = 'Test2' 17 | Test3 = @{ 18 | Test4 = 'Test4' 19 | } 20 | } 21 | Test2 = @( 22 | "1", "2", "3" 23 | ) 24 | Test3 = [PSCustomObject] @{ 25 | Test4 = 'Test4' 26 | Test5 = 'Test5' 27 | } 28 | } 29 | 30 | $New1 = Copy-Dictionary -Dictionary $Test 31 | $New1 32 | 33 | .NOTES 34 | 35 | #> 36 | [alias('Copy-Hashtable', 'Copy-OrderedHashtable')] 37 | [cmdletbinding()] 38 | param( 39 | [System.Collections.IDictionary] $Dictionary 40 | ) 41 | $clone = [System.Management.Automation.PSSerializer]::Serialize($Dictionary, [int32]::MaxValue) 42 | return [System.Management.Automation.PSSerializer]::Deserialize($clone) 43 | } -------------------------------------------------------------------------------- /Public/Objects/Format-FirstXChars.ps1: -------------------------------------------------------------------------------- 1 | function Format-FirstXChars { 2 | <# 3 | .SYNOPSIS 4 | This function returns the first X characters of a given text string. 5 | 6 | .DESCRIPTION 7 | The Format-FirstXChars function takes a text string and a number of characters as input and returns the first X characters of the text string. 8 | 9 | .PARAMETER Text 10 | The input text string from which the first X characters will be extracted. 11 | 12 | .PARAMETER NumberChars 13 | The number of characters to extract from the beginning of the input text string. 14 | 15 | .EXAMPLE 16 | Format-FirstXChars -Text "VERBOSE: Loading module from path 'C:\Users\pklys\.vscode\extensions\ms-vs" -NumberChars 15 17 | # Returns: VERBOSE: Loading 18 | 19 | .NOTES 20 | This function is useful for truncating long text strings to a specific length. 21 | #> 22 | param( 23 | [string] $Text, 24 | [int] $NumberChars 25 | ) 26 | return ($Text.ToCharArray() | Select-Object -First $NumberChars) -join '' 27 | } -------------------------------------------------------------------------------- /Public/Objects/Get-Colors.ps1: -------------------------------------------------------------------------------- 1 | function Get-Colors { 2 | <# 3 | .SYNOPSIS 4 | Retrieves RGB color values based on the provided color names. 5 | 6 | .DESCRIPTION 7 | The Get-Colors function retrieves RGB color values from a predefined list based on the color names provided as input. If no color names are specified, it returns all available RGB color values. 8 | 9 | .PARAMETER Color 10 | Specifies an array of color names for which RGB values are to be retrieved. 11 | 12 | .EXAMPLE 13 | Get-Colors -Color "Red", "Green" 14 | Retrieves the RGB values for the colors Red and Green. 15 | 16 | .EXAMPLE 17 | Get-Colors 18 | Retrieves all available RGB color values. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param( 23 | [string[]] $Color 24 | ) 25 | if ($Color) { 26 | foreach ($_ in $Color) { 27 | $Script:RGBColors.$_ 28 | } 29 | } else { 30 | return $Script:RGBColors 31 | } 32 | } 33 | $ScriptBlockColors = { 34 | param($commandName, $parameterName, $wordToComplete, $commandAst, $fakeBoundParameters) 35 | $Script:RGBColors.Keys | Where-Object { $_ -like "*$wordToComplete*" } 36 | } 37 | 38 | Register-ArgumentCompleter -CommandName Get-Colors -ParameterName Color -ScriptBlock $ScriptBlockColors -------------------------------------------------------------------------------- /Public/Objects/Get-MimeType.ps1: -------------------------------------------------------------------------------- 1 | function Get-MimeType { 2 | <# 3 | .SYNOPSIS 4 | Get-MimeType function returns the MIME type of a file based on its extension. 5 | 6 | .DESCRIPTION 7 | This function takes a file name as input and returns the corresponding MIME type based on the file extension. 8 | 9 | .PARAMETER FileName 10 | Specifies the name of the file for which the MIME type needs to be determined. 11 | 12 | .EXAMPLE 13 | Get-MimeType -FileName "example.jpg" 14 | Returns "image/jpeg" as the MIME type for the file "example.jpg". 15 | 16 | .EXAMPLE 17 | Get-MimeType -FileName "example.png" 18 | Returns "image/png" as the MIME type for the file "example.png". 19 | #> 20 | [CmdletBinding()] 21 | param ( 22 | [Parameter(Mandatory = $true)] 23 | [string] $FileName 24 | ) 25 | 26 | $MimeMappings = @{ 27 | '.jpeg' = 'image/jpeg' 28 | '.jpg' = 'image/jpeg' 29 | '.png' = 'image/png' 30 | } 31 | 32 | $Extension = [System.IO.Path]::GetExtension( $FileName ) 33 | $ContentType = $MimeMappings[ $Extension ] 34 | 35 | if ([string]::IsNullOrEmpty($ContentType)) { 36 | return New-Object System.Net.Mime.ContentType 37 | } else { 38 | return New-Object System.Net.Mime.ContentType($ContentType) 39 | } 40 | } -------------------------------------------------------------------------------- /Public/Objects/Get-Types.ps1: -------------------------------------------------------------------------------- 1 | Function Get-Types { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the enum values of the specified types. 5 | 6 | .DESCRIPTION 7 | This function takes an array of types and returns the enum values of each type. 8 | 9 | .PARAMETER Types 10 | Specifies the types for which enum values need to be retrieved. 11 | 12 | .EXAMPLE 13 | Get-Types -Types [System.DayOfWeek] 14 | Retrieves the enum values of the System.DayOfWeek type. 15 | 16 | .EXAMPLE 17 | Get-Types -Types [System.ConsoleColor, System.EnvironmentVariableTarget] 18 | Retrieves the enum values of the System.ConsoleColor and System.EnvironmentVariableTarget types. 19 | #> 20 | [CmdletBinding()] 21 | param ( 22 | [Object] $Types 23 | ) 24 | $TypesRequired = foreach ($Type in $Types) { 25 | $Type.GetEnumValues() 26 | } 27 | return $TypesRequired 28 | } -------------------------------------------------------------------------------- /Public/Objects/Join-Uri.ps1: -------------------------------------------------------------------------------- 1 | function Join-Uri { 2 | <# 3 | .SYNOPSIS 4 | Provides ability to join two Url paths together 5 | 6 | .DESCRIPTION 7 | Provides ability to join two Url paths together 8 | 9 | .PARAMETER BaseUri 10 | Primary Url to merge 11 | 12 | .PARAMETER RelativeOrAbsoluteUri 13 | Additional path to merge with primary url 14 | 15 | .EXAMPLE 16 | Join-Uri 'https://evotec.xyz/' '/wp-json/wp/v2/posts' 17 | 18 | .EXAMPLE 19 | Join-Uri 'https://evotec.xyz/' 'wp-json/wp/v2/posts' 20 | 21 | .EXAMPLE 22 | Join-Uri -BaseUri 'https://evotec.xyz/' -RelativeOrAbsoluteUri '/wp-json/wp/v2/posts' 23 | 24 | .EXAMPLE 25 | Join-Uri -BaseUri 'https://evotec.xyz/test/' -RelativeOrAbsoluteUri '/wp-json/wp/v2/posts' 26 | 27 | .NOTES 28 | General notes 29 | #> 30 | [alias('Join-Url')] 31 | [cmdletBinding()] 32 | param( 33 | [parameter(Mandatory)][uri] $BaseUri, 34 | [parameter(Mandatory)][uri] $RelativeOrAbsoluteUri 35 | ) 36 | 37 | return ($BaseUri.OriginalString.TrimEnd('/') + "/" + $RelativeOrAbsoluteUri.OriginalString.TrimStart('/')) 38 | #return [Uri]::new([Uri]::new($BaseUri), $RelativeOrAbsoluteUri).ToString() 39 | #return [Uri]::new($BaseUri.OriginalString, $RelativeOrAbsoluteUri).ToString() 40 | } -------------------------------------------------------------------------------- /Public/Objects/Remove-WhiteSpace.ps1: -------------------------------------------------------------------------------- 1 | function Remove-WhiteSpace { 2 | <# 3 | .SYNOPSIS 4 | Removes leading, trailing, and extra white spaces from a given text string. 5 | 6 | .DESCRIPTION 7 | The Remove-WhiteSpace function removes any leading, trailing, and extra white spaces from the input text string. It ensures that only single spaces separate words within the text. 8 | 9 | .PARAMETER Text 10 | The input text string from which white spaces are to be removed. 11 | 12 | .EXAMPLE 13 | $MyValue = Remove-WhiteSpace -Text ' My Field ' 14 | # $MyValue now contains 'My Field' 15 | 16 | #> 17 | param( 18 | [string] $Text 19 | ) 20 | $Text = $Text -replace '(^\s+|\s+$)','' -replace '\s+',' ' 21 | return $Text 22 | } 23 | <# 24 | $MyValue = Remove-WhiteSpace -Text 'My Field ' 25 | Write-Color $MyValue, 'No' -Color White, Yellow 26 | 27 | #> -------------------------------------------------------------------------------- /Public/Objects/Rename-LatinCharacters.ps1: -------------------------------------------------------------------------------- 1 | Function Rename-LatinCharacters { 2 | <# 3 | .SYNOPSIS 4 | Renames a name to a name without special chars. 5 | 6 | .DESCRIPTION 7 | Renames a name to a name without special chars. 8 | 9 | .PARAMETER String 10 | Provide a string to rename 11 | 12 | .EXAMPLE 13 | Rename-LatinCharacters -String 'Przemysław Kłys' 14 | 15 | .EXAMPLE 16 | Rename-LatinCharacters -String 'Przemysław' 17 | 18 | .NOTES 19 | General notes 20 | #> 21 | [alias('Remove-StringLatinCharacters')] 22 | [cmdletBinding()] 23 | param( 24 | [string] $String 25 | ) 26 | [Text.Encoding]::ASCII.GetString([Text.Encoding]::GetEncoding("Cyrillic").GetBytes($String)) 27 | } -------------------------------------------------------------------------------- /Public/Objects/Test-IsDistinguishedName.ps1: -------------------------------------------------------------------------------- 1 | function Test-IsDistinguishedName { 2 | <# 3 | .SYNOPSIS 4 | Determines whether a given string is a valid Distinguished Name (DN) format. 5 | 6 | .DESCRIPTION 7 | This function checks if the provided string matches the format of a Distinguished Name (DN) in Active Directory. It validates the structure of a DN which typically consists of Common Name (CN), Organizational Unit (OU), and Domain Component (DC) components. 8 | 9 | .PARAMETER Identity 10 | Specifies the string to be tested as a Distinguished Name (DN). 11 | 12 | .EXAMPLE 13 | Test-IsDistinguishedName -Identity "CN=John Doe,OU=Users,DC=example,DC=com" 14 | This example checks if the given string is a valid Distinguished Name format. 15 | 16 | .NOTES 17 | Original source: https://github.com/PsCustomObject/IT-ToolBox/blob/master/Public/Test-IsValidDn.ps1 18 | 19 | #> 20 | [alias('Test-IsDN')] 21 | [cmdletBinding()] 22 | param ( 23 | [Parameter(Mandatory, ValueFromPipeline, ValueFromPipelineByPropertyName)] 24 | [Alias('DN', 'DistinguishedName')][string] $Identity 25 | ) 26 | Process { 27 | [regex]$distinguishedNameRegex = '^(?:(?CN=(?(?:[^,]|\,)*)),)?(?:(?(?:(?:CN|OU)=(?:[^,]|\,)+,?)+),)?(?(?:DC=(?:[^,]|\,)+,?)+)$' 28 | $Identity -match $distinguishedNameRegex 29 | } 30 | } -------------------------------------------------------------------------------- /Public/Programs/Find-MyProgramData.ps1: -------------------------------------------------------------------------------- 1 | function Find-MyProgramData { 2 | <# 3 | .SYNOPSIS 4 | Finds specific data within a given array of strings. 5 | 6 | .DESCRIPTION 7 | This function searches for a specific text within an array of strings and returns the second element of the string that matches the search criteria. 8 | 9 | .PARAMETER Data 10 | The array of strings to search through. 11 | 12 | .PARAMETER FindText 13 | The text to search for within the array of strings. 14 | 15 | .EXAMPLE 16 | Find-MyProgramData -Data @("Program A 123", "Program B 456", "Program C 789") -FindText "B" 17 | This example will return "456" as it finds the string containing "B" and returns the second element of that string. 18 | 19 | #> 20 | [CmdletBinding()] 21 | param ( 22 | $Data, 23 | $FindText 24 | ) 25 | foreach ($Sub in $Data) { 26 | if ($Sub -like $FindText) { 27 | $Split = $Sub.Split(' ') 28 | return $Split[1] 29 | } 30 | } 31 | return '' 32 | } -------------------------------------------------------------------------------- /Public/Programs/Start-InternalFunction.ps1: -------------------------------------------------------------------------------- 1 | function Start-InternalFunction { 2 | <# 3 | .SYNOPSIS 4 | Starts an internal function within a specified module. 5 | 6 | .DESCRIPTION 7 | This function starts an internal function within a specified module by importing the module and executing the provided script block. 8 | 9 | .PARAMETER ScriptBlock 10 | Specifies the script block to be executed as the internal function. 11 | 12 | .PARAMETER Module 13 | Specifies the name of the module containing the internal function. 14 | 15 | .EXAMPLE 16 | Start-InternalFunction -ScriptBlock { Get-ChildItem } -Module "ExampleModule" 17 | This example starts the internal function 'Get-ChildItem' within the 'ExampleModule' module. 18 | 19 | #> 20 | [CmdletBinding()] 21 | param( 22 | [ScriptBlock] $ScriptBlock, 23 | [string] $Module 24 | ) 25 | 26 | $InternalModule = Import-Module -Name $Module -PassThru 27 | & $InternalModule $ScriptBlock 28 | } -------------------------------------------------------------------------------- /Public/Random/Get-RandomCharacters.ps1: -------------------------------------------------------------------------------- 1 | function Get-RandomCharacters { 2 | <# 3 | .SYNOPSIS 4 | Generates a random string of characters from a specified character set. 5 | 6 | .DESCRIPTION 7 | This function generates a random string of characters from a specified character set with the given length. 8 | 9 | .PARAMETER length 10 | The length of the random string to generate. 11 | 12 | .PARAMETER characters 13 | The set of characters from which to generate the random string. 14 | 15 | .EXAMPLE 16 | Get-RandomCharacters -length 8 -characters 'abcdef123' 17 | Generates a random string of 8 characters from the character set 'abcdef123'. 18 | 19 | .EXAMPLE 20 | Get-RandomCharacters -length 12 -characters 'ABC123!@#' 21 | Generates a random string of 12 characters from the character set 'ABC123!@#'. 22 | #> 23 | [cmdletbinding()] 24 | param( 25 | [int] $length, 26 | [string] $characters 27 | ) 28 | if ($length -ne 0 -and $characters -ne '') { 29 | $random = 1..$length | ForEach-Object { Get-Random -Maximum $characters.length } 30 | $private:ofs = "" # https://blogs.msdn.microsoft.com/powershell/2006/07/15/psmdtagfaq-what-is-ofs/ 31 | return [String]$characters[$random] 32 | } else { 33 | return 34 | } 35 | } -------------------------------------------------------------------------------- /Public/Random/Get-RandomFileName.ps1: -------------------------------------------------------------------------------- 1 | function Get-RandomFileName { 2 | <# 3 | .SYNOPSIS 4 | Generates a random file name with a specified length and extension. 5 | 6 | .DESCRIPTION 7 | This function generates a random file name with a specified length and extension. The file name is created using random letters only. 8 | 9 | .PARAMETER Length 10 | The length of the random file name to generate. Default is 16. 11 | 12 | .PARAMETER Extension 13 | The extension to append to the random file name. 14 | 15 | .EXAMPLE 16 | Get-RandomFileName -Length 8 -Extension "txt" 17 | Generates a random file name with a length of 8 characters and appends the extension ".txt". 18 | 19 | .EXAMPLE 20 | Get-RandomFileName -Extension "docx" 21 | Generates a random file name with a default length of 16 characters and appends the extension ".docx". 22 | #> 23 | [cmdletbinding()] 24 | param( 25 | $Length = 16, 26 | $Extension 27 | ) 28 | $File = Get-RandomStringName -Size $Length -LettersOnly -ToLower 29 | return "$File.$Extension" 30 | } -------------------------------------------------------------------------------- /Public/Runspaces/New-Runspace.ps1: -------------------------------------------------------------------------------- 1 | function New-Runspace { 2 | <# 3 | .SYNOPSIS 4 | Creates a new runspace pool with the specified minimum and maximum runspaces. 5 | 6 | .DESCRIPTION 7 | This function creates a new runspace pool with the specified minimum and maximum runspaces. It allows for concurrent execution of PowerShell scripts. 8 | 9 | .PARAMETER minRunspaces 10 | The minimum number of runspaces to be created in the runspace pool. Default is 1. 11 | 12 | .PARAMETER maxRunspaces 13 | The maximum number of runspaces to be created in the runspace pool. Default is the number of processors plus 1. 14 | 15 | .EXAMPLE 16 | $pool = New-Runspace -minRunspaces 2 -maxRunspaces 5 17 | Creates a runspace pool with a minimum of 2 and a maximum of 5 runspaces. 18 | 19 | .EXAMPLE 20 | $pool = New-Runspace 21 | Creates a runspace pool with default minimum and maximum runspaces. 22 | 23 | #> 24 | [cmdletbinding()] 25 | param ( 26 | [int] $minRunspaces = 1, 27 | [int] $maxRunspaces = [int]$env:NUMBER_OF_PROCESSORS + 1 28 | ) 29 | $RunspacePool = [RunspaceFactory]::CreateRunspacePool($minRunspaces, $maxRunspaces) 30 | #ApartmentState is not available in PowerShell 6+ 31 | #$RunspacePool.ApartmentState = "MTA" 32 | $RunspacePool.Open() 33 | return $RunspacePool 34 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Get-ModulesAvailability.ps1: -------------------------------------------------------------------------------- 1 | Function Get-ModulesAvailability { 2 | <# 3 | .SYNOPSIS 4 | Checks the availability of a specified module and imports it if available. 5 | 6 | .DESCRIPTION 7 | This function checks if a specified module is available. If the module is not loaded, it attempts to import it. Returns $true if the module is successfully loaded, otherwise $false. 8 | 9 | .PARAMETER Name 10 | Specifies the name of the module to check and potentially import. 11 | 12 | .EXAMPLE 13 | Get-ModulesAvailability -Name "AzureRM" 14 | Checks if the "AzureRM" module is available and imports it if not already loaded. 15 | 16 | .EXAMPLE 17 | Get-ModulesAvailability -Name "ActiveDirectory" 18 | Checks the availability of the "ActiveDirectory" module and imports it if necessary. 19 | 20 | #> 21 | [cmdletBinding()] 22 | param( 23 | [string]$Name 24 | ) 25 | if (-not(Get-Module -Name $Name)) { 26 | if (Get-Module -ListAvailable | Where-Object { $_.Name -eq $Name }) { 27 | try { 28 | Import-Module -Name $Name 29 | return $true 30 | } catch { 31 | return $false 32 | } 33 | } else { 34 | #module not available 35 | return $false 36 | } 37 | } else { 38 | return $true 39 | } #module already loaded 40 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Search-Command.ps1: -------------------------------------------------------------------------------- 1 | function Search-Command { 2 | <# 3 | .SYNOPSIS 4 | Searches for a specific command by name. 5 | 6 | .DESCRIPTION 7 | This function checks if a command with the specified name exists in the current session. 8 | 9 | .PARAMETER CommandName 10 | Specifies the name of the command to search for. 11 | 12 | .EXAMPLE 13 | Search-Command -CommandName "Get-Process" 14 | Returns $true if the command "Get-Process" exists, otherwise $false. 15 | 16 | .EXAMPLE 17 | Search-Command -CommandName "UnknownCommand" 18 | Returns $false as "UnknownCommand" does not exist as a command. 19 | 20 | #> 21 | [cmdletbinding()] 22 | param ( 23 | [string] $CommandName 24 | ) 25 | return [bool](Get-Command -Name $CommandName -ErrorAction SilentlyContinue) 26 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Test-AvailabilityCommands.ps1: -------------------------------------------------------------------------------- 1 | function Test-AvailabilityCommands { 2 | <# 3 | .SYNOPSIS 4 | Tests the availability of specified commands. 5 | 6 | .DESCRIPTION 7 | The Test-AvailabilityCommands function checks whether the specified commands are available in the current environment. 8 | 9 | .PARAMETER Commands 10 | Specifies an array of command names to test for availability. 11 | 12 | .EXAMPLE 13 | Test-AvailabilityCommands -Commands "Get-Process", "Get-Service" 14 | This example tests the availability of the "Get-Process" and "Get-Service" commands. 15 | 16 | .EXAMPLE 17 | Test-AvailabilityCommands -Commands "Get-Command", "Get-Help" 18 | This example tests the availability of the "Get-Command" and "Get-Help" commands. 19 | 20 | #> 21 | [cmdletBinding()] 22 | param ( 23 | [string[]] $Commands 24 | ) 25 | $CommandsStatus = foreach ($Command in $Commands) { 26 | $Exists = Get-Command -Name $Command -ErrorAction SilentlyContinue 27 | if ($Exists) { 28 | Write-Verbose "Test-AvailabilityCommands - Command $Command is available." 29 | } else { 30 | Write-Verbose "Test-AvailabilityCommands - Command $Command is not available." 31 | } 32 | $Exists 33 | } 34 | return $CommandsStatus 35 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Test-ForestConnectivity.ps1: -------------------------------------------------------------------------------- 1 | function Test-ForestConnectivity { 2 | <# 3 | .SYNOPSIS 4 | Tests the connectivity to the Active Directory forest. 5 | 6 | .DESCRIPTION 7 | This function tests the connectivity to the Active Directory forest by attempting to retrieve the forest information. 8 | 9 | .EXAMPLE 10 | Test-ForestConnectivity 11 | Tests the connectivity to the Active Directory forest. 12 | 13 | #> 14 | [CmdletBinding()] 15 | param( 16 | 17 | ) 18 | Try { 19 | $null = Get-ADForest 20 | return $true 21 | } catch { 22 | #Write-Warning 'No connectivity to forest/domain.' 23 | return $False 24 | } 25 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Test-ModuleAvailability.ps1: -------------------------------------------------------------------------------- 1 | function Test-ModuleAvailability { 2 | <# 3 | .SYNOPSIS 4 | Tests the availability of required modules. 5 | 6 | .DESCRIPTION 7 | This function checks if the required modules are available for use. 8 | 9 | .EXAMPLE 10 | Test-ModuleAvailability 11 | Checks if the 'Get-AdForest' module is available. 12 | 13 | #> 14 | [CmdletBinding()] 15 | param( 16 | 17 | ) 18 | if (Search-Command -CommandName 'Get-AdForest') { 19 | # future use 20 | } else { 21 | Write-Warning 'Modules required to run not found.' 22 | Exit 23 | } 24 | } -------------------------------------------------------------------------------- /Public/TestFunctionality/Test-WinRM.ps1: -------------------------------------------------------------------------------- 1 | function Test-WinRM { 2 | <# 3 | .SYNOPSIS 4 | Tests the WinRM connectivity on the specified computers. 5 | 6 | .DESCRIPTION 7 | The Test-WinRM function tests the WinRM connectivity on the specified computers and returns the status of the connection. 8 | 9 | .PARAMETER ComputerName 10 | Specifies the names of the computers to test WinRM connectivity on. 11 | 12 | .EXAMPLE 13 | Test-WinRM -ComputerName "Server01", "Server02" 14 | Tests the WinRM connectivity on Server01 and Server02. 15 | 16 | .EXAMPLE 17 | Test-WinRM -ComputerName "Server03" 18 | Tests the WinRM connectivity on Server03. 19 | 20 | #> 21 | [CmdletBinding()] 22 | param ( 23 | [alias('Server')][string[]] $ComputerName 24 | ) 25 | $Output = foreach ($Computer in $ComputerName) { 26 | $Test = [PSCustomObject] @{ 27 | Output = $null 28 | Status = $null 29 | ComputerName = $Computer 30 | } 31 | try { 32 | $Test.Output = Test-WSMan -ComputerName $Computer -ErrorAction Stop 33 | $Test.Status = $true 34 | } catch { 35 | $Test.Status = $false 36 | } 37 | $Test 38 | } 39 | $Output 40 | } 41 | 42 | #Test-WinRM -ComputerName AD1, AD2 -------------------------------------------------------------------------------- /Public/Time/Get-TimeZoneLegacy.ps1: -------------------------------------------------------------------------------- 1 | function Get-TimeZoneLegacy () { 2 | <# 3 | .SYNOPSIS 4 | Retrieves the standard name of the current time zone. 5 | 6 | .DESCRIPTION 7 | The Get-TimeZoneLegacy function retrieves the standard name of the current time zone using the legacy method. 8 | 9 | .EXAMPLE 10 | Get-TimeZoneLegacy 11 | # Output: "Pacific Standard Time" 12 | 13 | #> 14 | return ([System.TimeZone]::CurrentTimeZone).StandardName 15 | } 16 | -------------------------------------------------------------------------------- /Public/Time/Measure-Collection.ps1: -------------------------------------------------------------------------------- 1 | function Measure-Collection { 2 | <# 3 | .SYNOPSIS 4 | Measures the execution time of a script block and outputs the duration. 5 | 6 | .DESCRIPTION 7 | This function measures the time taken to execute a given script block and outputs the duration in days, hours, minutes, seconds, milliseconds, and ticks. 8 | 9 | .PARAMETER Name 10 | Specifies the name of the measurement. 11 | 12 | .PARAMETER ScriptBlock 13 | Specifies the script block to be executed and measured. 14 | 15 | .EXAMPLE 16 | Measure-Collection -Name "Example" -ScriptBlock { Start-Sleep -Seconds 5 } 17 | # Outputs: Name: Example, 0 days, 0 hours, 0 minutes, 5 seconds, 0 milliseconds, ticks 5000000 18 | 19 | .EXAMPLE 20 | Measure-Collection -Name "Another Example" -ScriptBlock { Get-Process } 21 | # Outputs: Name: Another Example, 0 days, 0 hours, 0 minutes, X seconds, Y milliseconds, ticks Z 22 | 23 | #> 24 | param( 25 | [string] $Name, 26 | [ScriptBlock] $ScriptBlock 27 | ) 28 | $Time = [System.Diagnostics.Stopwatch]::StartNew() 29 | Invoke-Command -ScriptBlock $ScriptBlock 30 | $Time.Stop() 31 | "Name: $Name, $($Time.Elapsed.Days) days, $($Time.Elapsed.Hours) hours, $($Time.Elapsed.Minutes) minutes, $($Time.Elapsed.Seconds) seconds, $($Time.Elapsed.Milliseconds) milliseconds, ticks $($Time.Elapsed.Ticks)" 32 | } -------------------------------------------------------------------------------- /Public/Time/Start-TimeLog.ps1: -------------------------------------------------------------------------------- 1 | function Start-TimeLog { 2 | <# 3 | .SYNOPSIS 4 | Starts a new stopwatch for logging time. 5 | 6 | .DESCRIPTION 7 | This function starts a new stopwatch that can be used for logging time durations. 8 | 9 | .EXAMPLE 10 | Start-TimeLog 11 | Starts a new stopwatch for logging time. 12 | 13 | #> 14 | [CmdletBinding()] 15 | param() 16 | [System.Diagnostics.Stopwatch]::StartNew() 17 | } -------------------------------------------------------------------------------- /Public/Vizualization/Show-Array.ps1: -------------------------------------------------------------------------------- 1 | function Show-Array { 2 | <# 3 | .SYNOPSIS 4 | Displays the elements of an ArrayList with optional type information. 5 | 6 | .DESCRIPTION 7 | The Show-Array function displays each element of the provided ArrayList. Optionally, it can also show the type of each element. 8 | 9 | .PARAMETER List 10 | Specifies the ArrayList containing the elements to display. 11 | 12 | .PARAMETER WithType 13 | Switch parameter to include type information along with each element. 14 | 15 | .EXAMPLE 16 | $myList = New-Object System.Collections.ArrayList 17 | $myList.Add("Apple") 18 | $myList.Add(42) 19 | Show-Array -List $myList 20 | # Output: 21 | # Apple 22 | # 42 23 | 24 | .EXAMPLE 25 | $myList = New-Object System.Collections.ArrayList 26 | $myList.Add("Banana") 27 | $myList.Add(3.14) 28 | Show-Array -List $myList -WithType 29 | # Output: 30 | # Banana (Type: String) 31 | # 3.14 (Type: Double) 32 | #> 33 | [CmdletBinding()] 34 | param( 35 | [System.Collections.ArrayList] $List, 36 | [switch] $WithType 37 | ) 38 | foreach ($Element in $List) { 39 | $Type = Get-ObjectType -Object $Element 40 | if ($WithType) { 41 | Write-Output "$Element (Type: $($Type.ObjectTypeName))" 42 | } else { 43 | Write-Output $Element 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /Public/Vizualization/Show-DataInVerbose.ps1: -------------------------------------------------------------------------------- 1 | function Show-DataInVerbose { 2 | <# 3 | .SYNOPSIS 4 | Displays the properties of an object in a verbose manner. 5 | 6 | .DESCRIPTION 7 | This function takes an object as input and displays each property of the object in a verbose format. 8 | 9 | .PARAMETER Object 10 | Specifies the object whose properties will be displayed. 11 | 12 | .EXAMPLE 13 | $data = [PSCustomObject]@{ 14 | Name = "John Doe" 15 | Age = 30 16 | City = "New York" 17 | } 18 | Show-DataInVerbose -Object $data 19 | 20 | Description: 21 | Displays the properties of the $data object in a verbose manner. 22 | 23 | #> 24 | [CmdletBinding()] 25 | param( 26 | [Object] $Object 27 | ) 28 | foreach ($O in $Object) { 29 | foreach ($E in $O.PSObject.Properties) { 30 | $FieldName = $E.Name 31 | $FieldValue = $E.Value 32 | Write-Verbose "Display-DataInVerbose - FieldName: $FieldName FieldValue: $FieldValue" 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /Public/XML/Save-XML.ps1: -------------------------------------------------------------------------------- 1 | function Save-XML { 2 | <# 3 | .SYNOPSIS 4 | Saves an XML document to a specified file path. 5 | 6 | .DESCRIPTION 7 | This function saves an XML document to a specified file path using UTF-8 encoding without BOM. 8 | 9 | .PARAMETER FilePath 10 | Specifies the path where the XML document will be saved. 11 | 12 | .PARAMETER xml 13 | Specifies the XML document to be saved. 14 | 15 | .EXAMPLE 16 | Save-XML -FilePath "C:\Documents\example.xml" -xml $xmlDocument 17 | Saves the XML document $xmlDocument to the file "example.xml" located in the "C:\Documents" directory. 18 | 19 | #> 20 | param ( 21 | [string] $FilePath, 22 | [System.Xml.XmlNode] $xml 23 | ) 24 | $utf8WithoutBom = New-Object System.Text.UTF8Encoding($false) 25 | $writer = New-Object System.IO.StreamWriter($FilePath, $false, $utf8WithoutBom) 26 | $xml.Save( $writer ) 27 | $writer.Close() 28 | } -------------------------------------------------------------------------------- /Public/XML/Set-XML.ps1: -------------------------------------------------------------------------------- 1 | function Set-XML { 2 | <# 3 | .SYNOPSIS 4 | Sets a specific node value in an XML file. 5 | 6 | .DESCRIPTION 7 | This function sets the value of a specified node in an XML file at the given path. 8 | 9 | .PARAMETER FilePath 10 | The path to the XML file. 11 | 12 | .PARAMETER Paths 13 | An array of paths to navigate through the XML structure. 14 | 15 | .PARAMETER Node 16 | The name of the node to set the value for. 17 | 18 | .PARAMETER Value 19 | The value to set for the specified node. 20 | 21 | .EXAMPLE 22 | Set-XML -FilePath "C:\example.xml" -Paths "Root", "Child" -Node "Value" -Value "NewValue" 23 | Sets the value of the "Value" node under "Root/Child" path in the XML file to "NewValue". 24 | 25 | .NOTES 26 | File encoding is assumed to be UTF-8. 27 | 28 | #> 29 | param ( 30 | [string] $FilePath, 31 | [string[]]$Paths, 32 | [string] $Node, 33 | [string] $Value 34 | ) 35 | [xml]$xmlDocument = Get-Content -Path $FilePath -Encoding UTF8 36 | $XmlElement = $xmlDocument 37 | foreach ($Path in $Paths) { 38 | $XmlElement = $XmlElement.$Path 39 | } 40 | $XmlElement.$Node = $Value 41 | $xmlDocument.Save($FilePath) 42 | # Save-XML -FilePath $FilePath -xml $xmlDocument 43 | } -------------------------------------------------------------------------------- /Tests/Format-ToTitleCase.Tests.ps1: -------------------------------------------------------------------------------- 1 | Describe -Name 'Testing Format-ToTitleCase' { 2 | It 'Test very long sentence and removee some special chars and spaces' { 3 | $String = Format-ToTitleCase -Text "This is my thing: That - No I don't want all chars" -RemoveWhiteSpace -RemoveChar ',', '-', "'", '\(', '\)', ':' 4 | $String | Should -BeExactly 'ThisIsMyThingThatNoIDontWantAllChars' 5 | } 6 | It 'Test long sentance and remove spaces' { 7 | Format-ToTitleCase -Text 'This is my thing' -RemoveWhiteSpace | Should -BeExactly 'ThisIsMyThing' 8 | } 9 | It 'Test pipeline with 2 strings' { 10 | $String = 'me i feel', 'not feel' | Format-ToTitleCase 11 | $String[0] | Should -BeExactly 'Me I Feel' 12 | $String[1] | Should -BeExactly 'Not Feel' 13 | } 14 | It 'Testing long string' { 15 | $String = 'me i feel good' | Format-ToTitleCase 16 | $String | Should -BeExactly 'Me I Feel Good' 17 | } 18 | It 'Testing short string' { 19 | Format-ToTitleCase 'MerRe' | Should -BeExactly 'Merre' 20 | } 21 | } -------------------------------------------------------------------------------- /Tests/Join-Uri.Tests.ps1: -------------------------------------------------------------------------------- 1 | Describe 'Join-Uri' { 2 | It 'Testing Join-Uri joining two paths - 1' { 3 | $JoinOutput = Join-Uri 'https://evotec.xyz/' '/wp-json/wp/v2/posts' 4 | $JoinOutput | Should -Be 'https://evotec.xyz/wp-json/wp/v2/posts' 5 | } 6 | It 'Testing Join-Uri joining two paths - 2' { 7 | $JoinOutput = Join-Uri 'https://evotec.xyz/' 'wp-json/wp/v2/posts' 8 | $JoinOutput | Should -Be 'https://evotec.xyz/wp-json/wp/v2/posts' 9 | } 10 | It 'Testing Join-Uri joining two paths - 3' { 11 | $JoinOutput = Join-Uri -BaseUri 'https://evotec.xyz/' -RelativeOrAbsoluteUri '/wp-json/wp/v2/posts' 12 | $JoinOutput | Should -Be 'https://evotec.xyz/wp-json/wp/v2/posts' 13 | } 14 | It 'Testing Join-Uri joining two paths - 4' { 15 | $JoinOutput = Join-Uri -BaseUri 'https://evotec.xyz/wp-json/wp/v2/' -RelativeOrAbsoluteUri '/posts' 16 | $JoinOutput | Should -Be 'https://evotec.xyz/wp-json/wp/v2/posts' 17 | } 18 | } -------------------------------------------------------------------------------- /Tests/Join-UriQuery.ps1: -------------------------------------------------------------------------------- 1 | Describe 'Join-UriQuery' { 2 | It 'Testing Join-UriQuery joining two paths and multiple queries' { 3 | $JoinOutput = Join-UriQuery -BaseUri 'https://evotec.xyz/' -RelativeOrAbsoluteUri '/wp-json/wp/v2/posts' -QueryParameter ([ordered]@{ 4 | page = 1 5 | per_page = 20 6 | search = 'SearchString' 7 | }) 8 | $JoinOutput | Should -Be 'https://evotec.xyz/wp-json/wp/v2/posts?page=1&per_page=20&search=SearchString' 9 | } 10 | } -------------------------------------------------------------------------------- /Tests/Select-Properties.Tests.ps1: -------------------------------------------------------------------------------- 1 | Describe 'Select-Properties' { 2 | It 'Select-Properties - Testing Array of PSCustomObjects' { 3 | 4 | $Object1 = [PSCustomobject] @{ 5 | Name1 = '1' 6 | Name2 = '3' 7 | Name3 = '5' 8 | } 9 | $Object2 = [PSCustomobject] @{ 10 | Name4 = '2' 11 | Name5 = '6' 12 | Name6 = '7' 13 | } 14 | 15 | Select-Properties -Objects $Object1, $Object2 -AllProperties | Should -Be Name1, Name2, Name3, Name4, Name5, Name6 16 | $Object1, $Object2 | Select-Properties -AllProperties | Should -Be Name1, Name2, Name3, Name4, Name5, Name6 17 | $Object1, $Object2 | Select-Properties -AllProperties -ExcludeProperty Name6 -Property Name3 | Should -Be Name3 18 | 19 | } 20 | It 'Select-Properties - Testing Array of OrderedDictionary' { 21 | $Object3 = [Ordered] @{ 22 | Name1 = '1' 23 | Name2 = '3' 24 | Name3 = '5' 25 | } 26 | $Object4 = [Ordered] @{ 27 | Name4 = '2' 28 | Name5 = '6' 29 | Name6 = '7' 30 | } 31 | 32 | Select-Properties -Objects $Object3, $Object4 -AllProperties | Should -Be Name1, Name2, Name3, Name4, Name5, Name6 33 | $Object3, $Object4 | Select-Properties -AllProperties | Should -Be Name1, Name2, Name3, Name4, Name5, Name6 34 | } 35 | } -------------------------------------------------------------------------------- /Tests/Test-IsDistinguishedName.Tests.ps1: -------------------------------------------------------------------------------- 1 | Describe 'Test-IsDistinguishedName' { 2 | It 'Direct input' { 3 | Test-IsDistinguishedName -Identity 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Should -Be $true 4 | Test-IsDistinguishedName -Identity 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Should -Be $true 5 | Test-IsDistinguishedName -Identity 'ad.evotec.pl' | Should -Be $false 6 | Test-IsDistinguishedName -Identity 'test.evotec.pl' | Should -Be $false 7 | Test-IsDistinguishedName -Identity 'NT AUTHORITY\INTERACTIVE' | Should -Be $false 8 | Test-IsDistinguishedName -Identity 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Should -Be $true 9 | 10 | } 11 | It 'Pipeline input' { 12 | 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Test-IsDistinguishedName | Should -Be $true 13 | 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Test-IsDistinguishedName | Should -Be $true 14 | 'ad.evotec.pl' | Test-IsDistinguishedName | Should -Be $false 15 | 'test.evotec.pl' | Test-IsDistinguishedName | Should -Be $false 16 | 'NT AUTHORITY\INTERACTIVE' | Test-IsDistinguishedName | Should -Be $false 17 | 'CN=Domain Admins,CN=Users,DC=ad,DC=evotec,DC=pl' | Test-IsDistinguishedName | Should -Be $true 18 | } 19 | } --------------------------------------------------------------------------------