{"id":3228,"date":"2025-02-19T20:32:39","date_gmt":"2025-02-19T20:32:39","guid":{"rendered":"https:\/\/foghosting.com\/how-to-install-visual-studio-code-on-ubuntu-fog-hosting\/"},"modified":"2025-02-19T20:32:39","modified_gmt":"2025-02-19T20:32:39","slug":"how-to-install-visual-studio-code-on-ubuntu-fog-hosting","status":"publish","type":"post","link":"https:\/\/foghosting.com\/blog\/how-to-install-visual-studio-code-on-ubuntu-fog-hosting\/","title":{"rendered":"How to Install Visual Studio Code on Ubuntu? &#8211; Fog Hosting"},"content":{"rendered":"<div id=\"content\">\n<div role=\"main\">\n<div>\n<figure><\/figure>\n<\/div>\n<div>\n<h2><span id=\"Introduction\">Introduction\u00a0<\/span><\/h2>\n<p>As an esteemed code editor, Microsoft\u2019s VScode is a tool developers gravitate towards for its exceptional functionality in editing source code. What\u2019s more, VScode is compatible with the three major operating systems \u2013 Windows, macOS, and Linux. This means that its clean and user-friendly interface can be accessed regardless of your preferred OS, making it highly compatible with Linux-based OS, Ubuntu in particular.\u00a0<\/p>\n<p>Unlike Ubuntu\u2019s built-in command-line-interface text editors, Nano and Vim, Visual Studio is a GUI code editor. To ensure uninterrupted usage, it is important to have the supported version of Ubuntu OS and to update Visual Studio once installed from the official Microsoft repository regularly. If you\u2019re looking to delve into the technical details of how to <strong>install Visual Studio code on Ubuntu<\/strong>, then let\u2019s explore further!<\/p>\n<p>To <strong>install Visual Studio code on Ubuntu<\/strong>, you need a terminal (text-based interface like command-kline-interface). Follow the following steps to install <strong>Visual Studio from the terminal<\/strong>.\u00a0<\/p>\n<ul>\n<li>Open the terminal window on your Ubuntu system.<\/li>\n<li>Now you need to import the Microsoft GPG key (a digital signature tool) to sign the package. Use the below code to import the key.<\/li>\n<\/ul>\n<pre><code>curl -sSL https:\/\/packages.microsoft.com\/keys\/microsoft.asc |<\/code><\/pre>\n<pre><code>gpg --dearmor > microsoft.gpg<\/code><\/pre>\n<figure><\/figure>\n<p>sudo mv microsoft.gpg \/etc\/apt\/trusted.gpg.d\/microsoft.gpg<\/p>\n<figure><\/figure>\n<ul>\n<li>After you have verified the authentification of the vscode, you need to add the vscode repository to Ubuntu\u2019s software sources list. The following code will help you in adding the repository.<\/li>\n<\/ul>\n<pre><code>echo \"deb [arch=amd64 signed-<\/code><\/pre>\n<pre><code>by=\/etc\/apt\/trusted.gpg.d\/microsoft.gpg]\u00a0<\/code><\/pre>\n<pre><code>https:\/\/packages.microsoft.com\/repos\/vscode stable main\" |\u00a0<\/code><\/pre>\n<pre><code>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 sudo tee \/etc\/apt\/sources.list.d\/vscode.list<\/code><\/pre>\n<ul>\n<li>The next step involves the updation of the package list through the below code.<\/li>\n<\/ul>\n<pre><code>sudo apt update<\/code><\/pre>\n<figure><\/figure>\n<ul>\n<li>The last step of this<strong> installation process of Visual Studio on Ubuntu<\/strong> involves the following code.\u00a0<\/li>\n<\/ul>\n<pre><code>sudo apt install code<\/code><\/pre>\n<figure><\/figure>\n<ul>\n<li>When your installation is complete, simply type the command \u201ccode\u201d in the terminal.<\/li>\n<\/ul>\n<figure><\/figure>\n<p>Also Read: How to Format a Disk in Linux\/Ubuntu OS?<\/p>\n<h2><span id=\"How_to_Start_Visual_Studio_on_Ubuntu\">How to Start Visual Studio on Ubuntu?\u00a0<\/span><\/h2>\n<p>Once you have properly installed Visual Studio in Ubuntu, you need to start the code editor. Follow the below steps to start the software tool quickly.<\/p>\n<ul>\n<li>If you want to start the code editor directly through the application menu, then search Visual Studio or code in the menu. The application menu is present on the top-left corner of the screen.<\/li>\n<li>Another method is to use the command-line interface. Search for the terminal through the application menu. Click on the terminal window and type \u2018code.\u2019 The Visual Studio will launch after you press enter.\u00a0<\/li>\n<\/ul>\n<p>You can now enjoy the code editing software vscode.<\/p>\n<h2><span id=\"Uninstall_vscode\">Uninstall vscode\u00a0<\/span><\/h2>\n<p>Are your preferences shifted to other code editors, or do you simply have maintenance scheduled? In any case, you can easily uninstall vscode with the following steps.\u00a0<\/p>\n<ul>\n<li>First of all, we will remove the vscode package by using this code in the terminal window.\u00a0<\/li>\n<\/ul>\n<pre><code>sudo apt remove code<\/code><\/pre>\n<figure><\/figure>\n<ul>\n<li>After the vscode package is removed, you can run the below code to configure the files associated with the software tool.<\/li>\n<\/ul>\n<pre><code>sudo apt purge code<\/code><\/pre>\n<figure><\/figure>\n<ul>\n<li>When you <strong>install vscode on Ubuntu<\/strong>, certain dependencies are also installed along with it. You can swiftly remove these dependencies with this code.<\/li>\n<\/ul>\n<pre><code>sudo apt autoremove<\/code><\/pre>\n<figure><\/figure>\n<p>Also Read: How to Add a GUI to Ubuntu Server<\/p>\n<h2><span id=\"Conclusion\">Conclusion<\/span><\/h2>\n<p>Visual Studio is a highly impressive code editor that can be used on a variety of operating systems. One such system is Ubuntu, which is based on Linux. If you\u2019re interested in<strong> installing vscode on Ubuntu<\/strong>, we\u2019ve got you covered. Thanks to its active community support, you can easily install Visual Studio via the terminal window. However, it\u2019s important to note that you will need to have the genuine Microsoft GPG key.\u00a0<\/p>\n<p>Once you\u2019ve successfully installed Visual Studio, you can access it through either the application menu or the terminal window. If you come across a better software tool or simply no longer need a code editor, removing Visual Studio is a breeze. You can quickly and easily remove the package and uninstall it within a matter of minutes. We hope that our article has provided you with both a clear understanding and detailed instructions.<\/p>\n<\/p><\/div>\n<div>\n<div>\n<h3>Arpit Saini<\/h3>\n<p>\n\t\t\t\t\tHe is the Director of Cloud Operations at Fog Hosting and also follows a passion to break complex tech topics into practical and easy-to-understand articles. He loves to write about Web Hosting, Software, Virtualization, Cloud Computing, and much more.\t\t\t\t<\/p>\n<\/p><\/div><\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Introduction\u00a0 As an esteemed code editor, Microsoft\u2019s VScode is a tool developers gravitate towards for its exceptional functionality in editing source code. What\u2019s more, VScode is compatible with the three major operating systems \u2013 Windows, macOS, and Linux. This means that its clean and user-friendly interface can be accessed regardless of your preferred OS, making<\/p>\n","protected":false},"author":3,"featured_media":3076,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"footnotes":""},"categories":[17],"tags":[],"class_list":["post-3228","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-dedicated-servers"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/posts\/3228","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/comments?post=3228"}],"version-history":[{"count":0,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/posts\/3228\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/media\/3076"}],"wp:attachment":[{"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/media?parent=3228"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/categories?post=3228"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/foghosting.com\/blog\/wp-json\/wp\/v2\/tags?post=3228"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}