简体   繁体   English

Visual Studio Code 无法在 Ubuntu 上运行

[英]Visual Studio Code doesnt run on Ubuntu

I followed the instruction here https://askubuntu.com/questions/616075/how-to-install-visual-studio-code-on-ubuntu to run Visual Studio Code https://code.visualstudio.com/我按照这里的说明https://askubuntu.com/questions/616075/how-to-install-visual-studio-code-on-ubuntu运行 Visual Studio Code https://code.visualstudio.com/

but nothing happens (no error message) when I double-click on application (named Code).但是当我双击应用程序(名为代码)时,没有任何反应(没有错误消息)。

In Ubuntu 16.04 and later Visual Studio Code should show up in Ubuntu Software application if you search for "vscode" or it can be installed from the terminal by running the command sudo snap install code --classic .在 Ubuntu 16.04 及更高版本中,如果您搜索“vscode”,或者可以通过运行命令sudo snap install code --classic从终端安装 Visual Studio Code 应该会显示在 Ubuntu 软件应用程序中。 A snap in classic confinement behaves as a traditionally packaged application with full access to the system, and Visual Studio Code extensions are installed into the user's home directory.经典限制中的 snap 作为传统打包应用程序具有对系统的完全访问权限,并且 Visual Studio Code 扩展安装到用户的主目录中。

Visual Studio Code is not an IDE, so it is not possible to create a project in Visual Studio Code, like it is in Visual Studio. Visual Studio Code 不是 IDE,因此无法像在 Visual Studio 中那样在 Visual Studio Code 中创建项目。 On the other hand it is possible to run Python, C, C++, JavaScript, PHP, Java, R and some other programming language code blocks directly in Visual Studio Code using the Code Runner extension.另一方面,可以使用 Code Runner 扩展直接在 Visual Studio Code 中运行 Python、C、C++、JavaScript、PHP、Java、R 和一些其他编程语言代码块。 Other extensions are required to get the debugging features of each programming language working.需要其他扩展才能使每种编程语言的调试功能正常工作。

Where you extracted code, you cannot double click on it.在您提取代码的地方,您不能双击它。 Easiest way is to right-click and select run.最简单的方法是右键单击并选择运行。 You can make the "code" icon executable by using the terminal.您可以使用终端使“代码”图标可执行。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM