mirror of
https://github.com/cmderdev/cmder.git
synced 2025-01-11 08:49:08 +08:00
Fixes Powershell loader issues
* Fix modules order required * Add newline before prompt * Fix color name
This commit is contained in:
parent
f5eb662783
commit
dc834cc28f
8
vendor/profile.ps1
vendored
8
vendor/profile.ps1
vendored
@ -5,8 +5,8 @@ $global:PsGetDestinationModulePath = $PSScriptRoot + "\..\vendor\psmodules"
|
|||||||
Push-Location -Path ($PsGetDestinationModulePath)
|
Push-Location -Path ($PsGetDestinationModulePath)
|
||||||
|
|
||||||
# Load modules from current directory
|
# Load modules from current directory
|
||||||
Get-ChildItem -Directory | `
|
Import-Module .\PsGet\PsGet
|
||||||
Foreach-Object{
|
Get-ChildItem -Exclude "PsGet" -Directory -Name | Foreach-Object {
|
||||||
Import-Module .\$_\$_
|
Import-Module .\$_\$_
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -16,8 +16,8 @@ Pop-Location
|
|||||||
# Set up a Cmder prompt, adding the git prompt parts inside git repos
|
# Set up a Cmder prompt, adding the git prompt parts inside git repos
|
||||||
function global:prompt {
|
function global:prompt {
|
||||||
$realLASTEXITCODE = $LASTEXITCODE
|
$realLASTEXITCODE = $LASTEXITCODE
|
||||||
$Host.UI.RawUI.ForegroundColor = "white"
|
$Host.UI.RawUI.ForegroundColor = "White"
|
||||||
Write-Host($pwd.ProviderPath) -NoNewLine -ForegroundColor "green"
|
Write-Host("`n" + $pwd.ProviderPath) -NoNewLine -ForegroundColor Green
|
||||||
if (Get-Module posh-git) {
|
if (Get-Module posh-git) {
|
||||||
Write-VcsStatus
|
Write-VcsStatus
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user