This file contains hidden or 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
### Get GMSAs | |
Get-ADServiceAccount -Filter '*' | Sort-Object -Property name | ft -Property name -HideTableHeaders | |
### Service Selected Details | |
Get-WmiObject -ComputerName SomeComputer -Class Win32_Service | Where-Object -Property StartName -match "Service|OtherService" | Format-Table -Property Name, StartName | |
### Service Executable | |
gwmi win32_service | Where-Object { $_.name -cmatch "SOMETHING" } | Format-Table -Property Name,PathName -Wrap | |
### Finding Services |
This file contains hidden or 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
ForegroundColour=131,148,150 | |
BackgroundColour=0,43,54 | |
CursorColour=255,255,0 | |
Black=7,54,66 | |
BoldBlack=0,43,54 | |
Red=220,50,47 | |
BoldRed=203,75,22 | |
Green=133,153,0 | |
BoldGreen=88,110,117 | |
Yellow=181,137,0 |
This file contains hidden or 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
### POSIX-To-Windows Path Conversion (Watch Out!) | |
export GIT_EDITOR="\"$( cygpath --absolute --long-name --windows /usr/bin/vim )\"" |
This file contains hidden or 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
#!/bin/bash | |
export PS1="${PS1//\\n$/\\n\[\\D\{%Y%m%d-%H%M\}]'\[\033[36m\]'\$'\[\033[0m\]'}" | |
export PS1="${PS1//\\n$/$'\[\033[34m\]' \`cygpath -w \$\{PWD\}\`\\n\[\\D\{%Y%m%d-%H%M\}]'\[\033[36m\]'\$'\[\033[0m\]'}" |
NewerOlder