Skip to main content

VS Code, Installation and Complete Setup

Let`s Install VS Code:


Which is the best source code editor available right now? Without no doubt, we can say that it’s Visual Studio code or simply VS code. VS code is an open-source code editor developed by Microsoft.

It has built-in support for C++, JavaScript, Node.js and almost all programing language-based plugins are available in VS studio right now.Let`s install the stable version of VS code on our Windows system:


Steps:

  • VS code setup file can be downloaded from the official website. Link is given- https://code.visualstudio.com/.

  • After opening the website, click on the Download for Windows button.This will download the VS code Setup Wizard on our system as an EXE file.
  • So, the VS code Setup Wizard is downloaded successfully, and we need to run it.
      1. Click on the setup file, a preview has been shown: -
            
    2. Agree to the License Agreement,
       3. Select the Installation Location,
       4. Placing the Shortcuts,
       5. Selecting Additional Tasks, select all the options as shown in preview (all not mandatory but should be added to path).

    6. Now, click on Next then install the VS code.
   7. After the successful installation Launch the VS code on your system now.

Installing the Compiler(GCC):

  • Open Windows PowerShell as run as administrator and type the following statement in it and press enter.Also this code given below keeps on updating and in case it doesn't work visit 'https://chocolatey.org/install'. (Copy exact code from below):
  • Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
    
  • The Chocolatey package manager for windows is installed in your PC.To use chocolatey restart PowerShell in Administrator Mode.
  • After restarting just type the following into the Powershell and press enter.
  • >choco install mingw
    
  • This is the preview of what it might look like:

  • When asked 'Do you want to run the script' type A as yes to all.
  • Then enter refreshenv the refresh the environment variable and close the shell, your GCC Compiler has been installed and added to path successfully.
  • Also you can use chocolatey to install different compilers and packages and to check those out visit https://chocolatey.org/packages and find relevant packages as per your need.
  • Like to install python or javascript type the following in PowerShell(administrator):
  • >choco install python
    >choco install nodejs
    

Now Setting Up the VS code:

Writing your first code running it-
  • Launch VS Code.
  • Type in your first Hello World program to run it. Also in the meantime you can check the the version of compiler by typing the following in the terminal of VS Code:
  • >gcc --version
    

  • Now to run the following program we must install Code-Runner, go to marketplace (has been encircled in preview) and search for it:

  • After you have installed go to Code Runnner extension`s settings:

  • Then check the following boxes (Run in terminal) so that you can take input in your programs from the settings menu of Code-Runner down the page-

  • After this last step is to install extensions for various programming languages, here we will install C++ extensions from the marketplace. I recommend C/C++ by Microsoft.

  • Now we will run our program, go to your HelloWorld Program and either press(Ctrl+src+N) or the run button at the top right section of the page to run your program and to get the desired output:

  • We always get the output in terminal window.

Few points to consider:

  • Using Chocolatey Package Installer for installing compiler nullify the mistake of installing wrong architecture compiler when done manually.
  • For VS code keyboard shortcuts please visit the following link: https://code.visualstudio.com/shortcuts/keyboard-shortcuts-windows.pdf
  • For compiling programs for other language please install proper extensions for the language and the compiler beforehand.
  • If you get any other error like .exe file not compatible with your system architecture, please contact me on Atul Sharma for further clarification.

Comments

Post a Comment

Popular posts from this blog

Programming Apps For Beginners

ARE YOU A PROGRAMMER OF BEGINNER LEVEL?? Having difficulty with programming or learning new technicla skills. THESE ANDROID APPS ARE FOR YOU… I , as a programmer , would like to suggest you these Apps which help you bring up your programming skills at a whole new level. 1.SoloLearn: Learn to code for Free This not just an Android app , but a large scale platform for enhancing your programming skills. Features *Take lessons of programming languages like C++, C#, Java, CSS, Python 3, JavaScript, PHP, HTML Fundamentals, SQL Fundamentals, jQuery, Ruby and Swift* *Challenge others and take challenges of your known languages to know how much you know.* Get certificates for completion of course. *Badges for your skills.* *Practice questions within the lessons.* Add and verify others’ questions for challenges. *Online Compiler for all languages* *Save progress and sync across devices* Much more. 2.Programming Hub, Learn to code This app has more languag

Android Automation

Android Automation Automate: Make your Phone or Tablet smarter with Automation This is a perfect platform for Android Automation. From setting the phone on silent during classes to low-level hacking, all can be performed and executed here. Just make flow with drag & drop approach on given blocks and then connecting them. This free app lets you automate various tasks on your smartphone or tablet. Create your automation with flowcharts, make your device automatically change settings like Bluetooth, Wi-Fi, NFC, or perform actions like sending SMS, e-mail, based on your location, the time of day, or any other “event trigger”. You can automate almost everything on your device, Automate even support plug-ins made for Tasker and Locale . Features of the App 1. Logical fun You edit flowcharts, just add blocks and connect the dots to create your automated tasks. 2. Simple, yet powerful Novices can pick from predefined options, while power users may use