Last active
September 27, 2017 12:08
-
-
Save kkoziarski/1694495935ce2ebb227cdfba2a4a5fc3 to your computer and use it in GitHub Desktop.
cmd PROMPT settings
This file contains hidden or 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
# Chocolatey profile | |
$ChocolateyProfile = "$env:ChocolateyInstall\helpers\chocolateyProfile.psm1" | |
if (Test-Path($ChocolateyProfile)) { | |
Import-Module "$ChocolateyProfile" | |
} | |
function PromptX { | |
# Print the working directory: | |
Write-Host ($PWD) -foregroundcolor Gray | |
# Print the promot symbol: | |
Write-Host (">") -nonewline -foregroundcolor Green | |
return " "; | |
} | |
Import-Module 'C:\tools\poshgit\dahlbyk-posh-git-a4faccd\src\posh-git.psd1' | |
$GitPromptSettings.DefaultPromptSuffix = '`n$(''>'' * ($nestedPromptLevel + 1)) ' | |
Set-PSReadlineOption -BellStyle None | |
Import-Module z |
This file contains hidden or 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
<# | |
>notepad $PROFILE | |
>notepad $env:USERPROFILE\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1 | |
C:\Users\USER_NAME\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1 | |
The profile scripts can be defined at one of the following locations: | |
%windir%\system32\WindowsPowerShellv1.0\profile.ps1 | |
(all users and all shells) | |
%windir%\system32\WindowsPowerShellv1.0\Microsoft.PowerShell_profile.ps1 | |
(all users, but only to the Microsoft.PowerShell shell) | |
%UserProfile%\My Documents\WindowsPowerShell\profile.ps1 | |
(the current user, but affects all shells) | |
%UserProfile%\My Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1 | |
(the current user and the Microsoft.PowerShell shell) | |
#> | |
function Prompt { | |
# Print the working directory: | |
Write-Host ($PWD) -foregroundcolor Gray | |
# Print the promot symbol: | |
Write-Host (">") -nonewline -foregroundcolor Green | |
return " "; | |
} | |
#disable beeping | |
Set-PSReadlineOption -BellStyle None |
This file contains hidden or 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
Create new environment variable: `PROMPT` | |
Set its value to: `$P$_$G` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment