问题描述
我在Widows Server 2012 R2上使用VSCode 1.49.0版用户设置。我将其用于Powershell开发。我的Windows 10笔记本电脑上没有这个问题,但是在服务器上却需要这样做,因为我是针对sharepoint 2013本地对象模型编写代码的。
我已安装Windows8.1-KB3118401 启动控制台后,我得到以下信息:
“ C:\ Windows \ System32 \ WindowsPowerShell \ v1.0 \ powershell.exe'-NoProfile','-NonInteractive','-ExecutionPolicy','Bypass','-Command','Import-Module'c :\ Users \ first.last.vscode \ extensions \ ms-vscode.powershell-2020.6.0 \ modules \ PowerShellEditorServices \ PowerShellEditorServices.psd1'; Start-EditorServices -HostName'Visual Studio代码主机' -HostProfileId'Microsoft.VSCode'-HostVersion'2020.6.0' -AdditionalModules @('PowerShellEditorServices.VSCode') -BundledModulesPath'c:\ Users \ first.last.vscode \ extensions \ ms-vscode.powershell-2020.6.0 \ modules' -EnableConsoleRepl -StartupBanner“ =====> PowerShell集成控制台v2020.6.0
当我尝试运行hello world测试脚本时,我得到:
在PowerShell会话之前无法调试或运行Powershell脚本 已开始。等待PowerShell会话完成启动,然后尝试 再次。
来源:PowerShell预览(扩展)
它似乎与Microsoft的Powershell 2020.6.0扩展有关,一旦我启用它,就会引发错误。
关于如何使Powershell再次工作的任何想法?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)