This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-DistributionGroupRecursive { | |
<# | |
.SYNOPSIS | |
Function providing missing -Recurse parameter for Get-DistributionGroup. | |
.DESCRIPTION | |
Takes an identity string and returns the matching distribution group and any nested groups beneath it. | |
Only distribution groups are returned, not mailboxes, etc. | |
.EXAMPLE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"sha256","md5" | % { $h = $_; gi "${env:ProgramData}\SSH\ssh_host_*_key.pub" | % { ssh-keygen -lf $_.FullName -E $h } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for h in {sha256,md5}; do for f in /etc/ssh/ssh_host_*_key.pub; do ssh-keygen -lf $f -E $h; done; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$k = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" | |
$v = (Get-ItemProperty -Path $k).SystemUsesLightTheme -bxor 1 | |
Set-ItemProperty -Path $k -Name "SystemUsesLightTheme" -Value $v | |
Set-ItemProperty -Path $k -Name "AppsUseLightTheme" -Value $v |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cp(gci([Environment]::GetFolderPath(22)) -r -fi *Outlook*.lnk).FullName ([Environment]::GetFolderPath(7)) |