VSCode/PyCharm解决“无法加载文件 ***\WindowsPowerShell\profile.ps1,因为在此系统上禁止运行脚本”
解决“无法加载文件 ***\WindowsPowerShell\profile.ps1,因为在此系统上禁止运行脚本”
博主在使用pycharm终端想用 Conda 初始化 Windows PowerShell 终端时
conda init powershell
报错:无法加载文件 ***\WindowsPowerShell\profile.ps1,因为在此系统上禁止运行脚本
查阅发现VSCode也有这个问题,应该是因为都用的Windows自带的PowerShell。评论区有人给出的命令可以解决此问题
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
执行命令后,再执行conda init powershell关掉终端重新打开就OK了

