Permalink
Browse files

Added a configuration option to add a new line between the prompt and…

… the cursor (since prompts can get long)
  • Loading branch information...
1 parent ba8625d commit 8ea33f55447d158cf5192f38e20142be83b0fbd1 @eamodio committed Feb 21, 2012
Showing with 8 additions and 2 deletions.
  1. +2 −0 GitPrompt.ps1
  2. +6 −2 profile.example.ps1
View
@@ -44,6 +44,8 @@ $global:GitPromptSettings = New-Object PSObject -Property @{
EnableFileStatus = $true
RepositoriesInWhichToDisableFileStatus = @( ) # Array of repository paths
+ PromptOnNewLine = $false
+
Debug = $false
}
View
@@ -22,8 +22,12 @@ function prompt {
$Host.UI.RawUI.WindowTitle = "$pwd $($GitStatus.Branch) - Windows Powershell"
$LASTEXITCODE = $realLASTEXITCODE
- Write-Host
- return "> "
+ if ($GitPromptSettings.PromptOnNewLine) {
+ return "`r`n> "
+ }
+ else {
+ return "> "
+ }
}
Enable-GitColors

0 comments on commit 8ea33f5

Please sign in to comment.