Last active
December 4, 2017 12:35
-
-
Save sqeezy/5d1647ce387d04fd814d4d1802990b26 to your computer and use it in GitHub Desktop.
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
function Set-PowershellPrompt{ | |
if (!(Test-Path -Path $PROFILE)){ New-Item -Path $PROFILE -ItemType File } ; ise $PROFILE | |
} | |
function prompt { | |
$origLastExitCode = $LASTEXITCODE | |
Write-VcsStatus | |
Write-Host $ExecutionContext.SessionState.Path.CurrentLocation -ForegroundColor Green | |
$LASTEXITCODE = $origLastExitCode | |
"$('>' * ($nestedPromptLevel + 1)) " | |
} | |
Get-ChildItem -Filter "*.ps*1" -File "~\Github\PsDevScripts" | ForEach-Object {Import-Module $_.FullName} | |
Import-Module posh-git | |
$global:GitPromptSettings.BeforeText = '[' | |
$global:GitPromptSettings.AfterText = '] ' | |
$GitPromptSettings.DefaultPromptAbbreviateHomeDirectory = $true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment