답변:
이미 Powershell 프로파일이있는 경우이 단계를 건너 뛰십시오.
New-Item $profile -force -itemtype file
그런 다음 프로파일을 편집하십시오.
notepad $profile
다음 줄을 추가하십시오.
remove-item alias:curl
아래 명령으로 메모장을 저장하고 닫은 후 프로파일을 다시로드하거나 Powershell을 닫았다가 열어 프로파일을 적용하십시오.
. $profile
Invoke-WebRequest구문이 아닌 실제 컬 명령 ...
curl.exe그냥 대신 사용을 고수 할 것 curl입니다. 이 방법은 특정 프로필로 실행되는 PowerShell에 의존하지 않으며 -NoProfile스위치를 사용하여 프로필없이 PowerShell을 실행할 수 있습니다 .
Remove-Item alias:curPowershell 자동 실행 스크립트에 추가
XP, 2003 이상 :
%ALLUSERSPROFILE%\Documents\Msh\profile.msh
%ALLUSERSPROFILE%\Documents\Msh\Microsoft.Management.Automation.msh_profile.msh
XP, 2003 :
%USERPROFILE%\My Documents\msh\profile.msh
%USERPROFILE%\My Documents\msh\Microsoft.Management.Automation.msh_profile.msh
Remove-Item alias:curl윈도우 서버 2019의 내부와 심지어 restaring 후 다시 표시되지 않습니다이다