powershell-profile
Pretty PowerShell that looks good and functions almost as good as Linux terminal
File Explorer
- bug_report.yml
- config.yml
- feature_request.yml
- CODE_OF_CONDUCT.md
- CONTRIBUTING.md
- FUNDING.yml
- PULL_REQUEST_TEMPLATE.md
- SECURITY.md
- .gitignore
- LICENSE
- Microsoft.PowerShell_profile.ps1
- README.md
- setprofile.ps1
- setup.ps1
# Use via CDN
jsDelivrjsDelivr serves any public GitHub repository as a CDN with zero setup. Pick a version and a file to get a ready-to-paste link and snippet.
Command Glossary
Commands referenced in this DOCs, explained below.
oh-my-posh
View Details ▼
oh-my-posh
Cross platform prompt engine for any shell.
oh-my-posh get shell
Display current shell name:
eval "$(oh-my-posh init bash --config {{path/to/theme}})"
Initialize for Bash:
oh-my-posh init pwsh --config {{path/to/theme}} | Invoke-Expression
Initialize for PowerShell:
pgrep
View Details ▼
pgrep
Find processes by name.
pgrep {{process_name}}
Return PIDs of any running processes with a matching command string:
pgrep {{process_name}}
Return PIDs of any running processes with a matching command string:
pgrep -l {{process_name}}
Print the process name in addition to the PID ([l]ong output):
pkill
View Details ▼
pkill
Signal process by name.
Mostly used for stopping processes.
pkill "{{process_name}}"
Kill all processes which match:
pkill {{[-f|--full]}} "{{command_name}}"
Kill all processes which match their full command instead of just the process name:
pkill {{[-9|-SIGKILL]}} "{{process_name}}"
Force kill matching processes (can't be blocked):
sed
View Details ▼
sed
Edit text in a scriptable manner.
See also: `awk`, `ed`.
{{command}} | sed 's/apple/mango/g'
Replace all `apple` (basic `regex`) occurrences with `mango` (basic `regex`) in all input lines and print the result to `stdout`:
{{command}} | sed 's/apple/mango/g'
Replace all `apple` (basic `regex`) occurrences with `mango` (basic `regex`) in all input lines and print the result to `stdout`:
{{command}} | sed 's/apple/mango/g'
[s]ubstitute all occurrences of "apple" with "mango" on all lines, print to `stdout`:
zoxide
View Details ▼
zoxide
Keep track of the most frequently used directories.
Uses a ranking algorithm to navigate to the best match.
zoxide query string
Go to the highest-ranked directory that contains `string` in the name:
zoxide query string1 string2
Go to the highest-ranked directory that contains `string1` and then `string2`:
zoxide query {{[-i|--interactive]}}
Start an interactive directory search (requires `fzf`):
trash
View Details ▼
trash
Manage the trashcan/recycling bin.
trash {{path/to/file}}
Send a file to the trash:
trash {{path/to/file}}
Move a file to the trash:
trash-list
List all files in the trash:
