Last active
December 16, 2020 21:11
-
-
Save boarnoah/e8b7c79c0b09a5c11fd4cbb27a65736d to your computer and use it in GitHub Desktop.
My personal powershell profile, has a few Powershell cmdlets aliased to a roughly similar linux utility for muscle memory purposes.
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
# Should be put into powershell's $PROFILE which acts similar to a .bashrc | |
# ex: notepad $PROFILE | |
New-Alias which Get-Command | |
# Get process by port #, ex: "port 8080" -> Find culprit process *cough* random postgres server *cough* | |
function port { | |
Get-Process -Id (Get-NetTCPConnection -LocalPort $args[0]).OwningProcess | |
} | |
New-Alias grep Select-String |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment