- Ubuntu 20.10, 22.04
- MacOS Monterey
- Windows 10
- Bash
- PowerShell
- Alacritty
- iTerm2
- Windows Terminal
- go
- make
In addition a Nerd Font needs to be installed on the system for icons to display. The Cousine Nerd Font is used in the sample image.
The Nerd Font must be v3 or later
make
make install
Add to ~/.bashrc
function set_prompt {
PS1=$($HOME/.local/bin/prompt)
}
if [[ -f "$HOME/.local/bin/prompt" ]]; then
PROMPT_COMMAND=set_prompt
fi
Add to $env:UserProfile\Documents\PowerShell\Microsoft.PowerShell_profile.ps1
function prompt {
if (Test-Path -Path "$env:LocalAppData\prompt\promptwin.exe" -PathType Leaf) {
# Only displaying the first line by default so forcing it
$a = invoke-expression "$env:LocalAppData\prompt\promptwin.exe"
$a[0] + "`r`n" + $a[1]
}
}
# Renders poorly upon first opening the shell, but fine afterwards
cls
# Required for unicode icons to show correctly
[Console]::OutputEncoding = [Text.UTF8Encoding]::UTF8