標籤:style blog http color io os ar for strong
(本文的修改方法參照http://www.cnblogs.com/grapeot/archive/2010/02/22/1670822.html,只是詳細列出修改的步驟之一。)
通過修改profile來實現,profile的介紹見http://technet.microsoft.com/en-us/library/bb613488(v=vs.85).aspx
1.更改其視窗背景和表徵圖,效果如下:
2.產生profile
先產看是否已經存在profile,
>test-path $profile
If the profile exists, the response is True; otherwise, it is False.
if not exists,then create it:
>new-item -path $profile -itemtype file –force
編輯產生的profile,填入以下的code:
function prompt { $path = Get-Location"$path>" }$host.UI.RawUI.WindowTitle = "C:\windows\system32\cmd.exe"$Shell = $Host.UI.RawUIClear-Host$str[email protected]"Microsoft Windows [Version 6.3.9600](c) 2013 Microsoft Corporation. All rights reserved."@$str
對於所有使用者生效的profile:
>new-item -path $env:windir\System32\WindowsPowerShell\v1.0\profile.ps1 -itemtype file -force
3.
不一樣的命令列 – Windows PowerShell簡介 之 “蛋疼的偽裝–Profile”詳細實現