Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
24 lines (22 sloc) 690 Bytes
<#
.SYNOPSIS
Format the prompt.
.DESCRIPTION
This prompt configuration displays the SesstionTitleName assinged in ConsoleTitle.ps1 and also adjusts the color
based on Test-Administrator.
.NOTES
Requires NameIt and posh-git Modules as well as the Test-Administrator funciton.
#>
function global:prompt
{
Write-Host ''
if (Test-Administrator) {
Write-Host "[$SessionTitleName] " -NoNewline -ForegroundColor Yellow
} else {
Write-Host "[$SessionTitleName] " -NoNewline -ForegroundColor DarkGray
}
Write-Host ($pwd.ProviderPath) -ForegroundColor DarkGray -NoNewline
Write-VcsStatus
Write-Host "`n`rposh" -NoNewline
return "> "
}