在配置前端开发环境的时候碰到一个VSCode 的配置问题,在VSCode 中启用项目的时候,发现默认终端(PowerShell)是空的

项目无法启动,这时候需要自己选择终端

git Bash :自己安装

Command Prompt: cmd 命令提示符

JavaScript Debug Terminal:debug 工具,需要PowerShell 才能使用

每次打开VSCode 启动项目每次都需要手动选择终端,我是一个懒人,这对我一点都不友好,必须设置VSCode 默认启动终端(找回VSCode的默认终端PowerShell)

1.打开VSCode设置

2.点击红色选框(将设置转为json)

3.查看你的终端配置,是否有 PowerShell 终端配置,如果有请看5,如果没有请看4

4.如果没有 PowerShell 终端,请参考复制下面代码(按需复制)

"terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"icon": "terminal-powershell"
},
"Command Prompt": {
"path": [
"${env:windir}\\Sysnative\\cmd.exe",
"${env:windir}\\System32\\cmd.exe"
],
"args": [],
"icon": "terminal-cmd"
},
"Git Bash": {
"source": "Git Bash"
}
},

5.配置默认启动终端 为 PowerShell 或 Windows PowerShell

"terminal.integrated.defaultProfile.windows": "Windows PowerShell",

1

重启VSCode 发现有了默认启动终端 PowerShell

如果没有,请设置你的PowerShell 权限

1.搜索powershell,以管理员身份运行。

2.输入set-ExecutionPolicy RemoteSigned

3.把权限改权限为A,然后通过 get-ExecutionPolicy 查看当前的状态:

重启VSCode 发现有了默认启动终端 PowerShell

最新文章

  1. mysql学习之 sql语句的技巧及优化
  2. Eclipse部署Maven web项目到tomcat服务器时,没有将lib下的jar复制过去的解决办法
  3. J2EE项目修改编码问题
  4. OD使用教程
  5. 通过实现Countable接口来调用count函数
  6. Python编码设置
  7. arcgis gdb含下划线_和%的查询 by gisoracle
  8. Oralce_语法
  9. 制作UI纹理(UI Texture)
  10. 使用php发送电子邮件(phpmailer)
  11. Stack的实现
  12. Boost学习之可移植路径操作--filesystem
  13. javascript DOM对象(1)
  14. excel中自动变为插入语句的写法
  15. margin 塌陷现象 与 注意事项
  16. 修改mysql root账号密码
  17. SpringMvc笔记-注解
  18. 大数据平台Lambda架构详解
  19. 小白学python时候总会遇到的几个问题
  20. es6(16)--Decorator

热门文章

  1. [WPF]程序随系统自启动
  2. 在不使用cv2等库的情况下利用numpy实现双线性插值缩放图像
  3. 腾讯出品小程序自动化测试框架【Minium】系列(四)API详解(上)
  4. 字节输出流的续写和换行-字节输入流_inputS Stream类
  5. 学习ASP.NET Core Blazor编程系列二十三——登录(3)
  6. Downie V4.6.4 for Mac 视频下载工具
  7. 1 - 【RocketMQ 系列】CentOS 7.6 安装部署RocketMQ
  8. windows C++
  9. 三:Mybatis
  10. SQL Server数据库日常检查