]> apps.delaporte.us Git - dotfiles.git/blob - files/Microsoft.PowerShell_profile.ps1
More tidying
[dotfiles.git] / files / Microsoft.PowerShell_profile.ps1
1 $env:src = "~\src"
2 Import-Module $env:src\dotfiles\psmodules\add_to_profile.psm1
3 Add-ToProfile $env:src\dotfiles\files\paths.ps1
4 Add-ToProfile $env:src\dotfiles\files\env.ps1
5 Add-ToProfile $env:src\dotfiles\files\load_modules.ps1
6
7 # Delay loading PoshGit for speed.
8 function Enable-PoshGit {
9 Import-Module posh-git
10 }
11 New-Alias pg Enable-PoshGit
12
13 # You can pry my unix commands out of my cold dead fingers
14 Set-Alias which get-command
15 # Reject Windows heritage, act like Vi
16 Set-PSReadlineOption -HistorySavePath $env:src\PSHistory.log
17 Set-PSReadlineOption -BellStyle Visual
18 Set-PSReadlineOption -ViModeIndicator Prompt
19 Set-PSReadlineOption -EditMode Vi
20
21 Write-Host "+ Type 'pg' to enable PoshGit"
22 Write-Host 'See $env:realProfile for version controlled profile file.'
23 # Let's face it, I'm about to cd into my source directory
24 if((Get-Location).Path -eq $HOME){ cd $env:src }