iex "& { $(irm https://aka.ms/install-powershell.ps1 -UseBasicParsing) }"
添加新配置文件
注意不是PowerShell里的Alias别名
New-Item $profile -force -itemtype file
notepad $profile
编辑配置文件function 别名 { 需要替代的命令 }
eg.
remove-item alias:history # 可选,删除默认的别名,否则会先调用默认的
function history { cat C:\Users\xxx\AppData\Roaming\Microsoft\Windows\PowerShell\PSReadLine\ConsoleHost_history.txt }
Set-ExecutionPolicy RemoteSigned
生效更改声明:转载请注明出处,原文地址:shlu's note