Visual Basic Code – My New Code Editor

I have been using Notepad++ in my Windows machine for some years and it’s one of favorite code editors. In recent years, I have been slowly moving to MacOS machines from Windows and in my MacOS machine I have installed Atom as my code editor. Although I use Atom for simple code editing but return to my Notepad++ for other operations, like comparison, find & replace etc. I love side side code comparison and code highlighting of Notepad++. Over the years, I have tested other code editors: Sublime Text, Bracket and others but still my favorite have been Notepad++ on my Windows machine.

Recently I have been reading from many developers posts that Microsoft’s Visual Studio Code is their choice of code editors. Most developers seem to look Microsoft’s product with suspicion, the Visual Code editor seems to be an exception. It has been written highly by many developer and I thought to give it a try for my MacOS machine.

Windows

VS Code editor installation on windows machine, as listed in official documentation include:

  • Download the Visual Studio Code installer for Windows.
  • Once it is downloaded, run the installer (VSCodeUserSetup-{version}.exe). This will only take a minute.
  • By default, VS Code is installed under C:\users\{username}\AppData\Local\Programs\Microsoft VS Code.
  • For configuration of set to PATH is simple in windows. From the console type 'code .' to open VS Code on that folder. Restart your console after the installation for the change to the %PATH% environmental variable to take effect.

MacOS Sierra

VS Code editor installation on windows machine, as listed in official documentation include:

  • Download VS Code Stable for MacOS from https://code.visualstudio.com/
  • Double-click on the downloaded archive to expand the contents.
  • Drag Visual Studio Code.app to the Applications folder, making it available in the Launchpad.
  • Add VS Code to your Dock by right-clicking on the icon and choosing Options, Keep in Dock.
Configure to Add Shell command

The VS Code documentation lists following steps to install shell command in MacOS machines:

  • VS Code Lunch
  • Go to View > Common Pellete >
  • Type shell command to find the shell command
  • From the shell command > type Install ‘code’ command in PATH to install.
    #! install command line $PATH
    > shell command
    shell command: install 'code' command in PATH
    #! to uninstall
    shell command: uninstall 'code' command from PATH
  • Restart the terminal to for the new $PATH to take effect.
Theme Installation

The VS Code Documentation lists following steps to select color themes.

  • Launch Visual Studio Code
  • Choose Extensions from menu (to select theme from marketplace)
  • Search for night-owl-vscode-theme
  • Click Install to install it
  • Click Reload to reload the Code
  • From the menu bar click: Code > Preferences > Color Theme > Night Owl to select Sarah Drasner’s Night owl from market place.

Two of my preferred color themes are New Moon VSCode – by Tania Rascia and Night Owl – by Sarah Drasner.

VS Code Extensions

VS Code provides built-in extensions out of the box. However they can be extended from the marketplace extension to improve desired workflow environment. VS Code documentation provides detailed instructions for Installation and managing extension. A few developers suggested extensions include:

Workspace Setting

VS Code workplace setting configuration can be done for user and workplace settings. The users settings are applied globally to any opened VS Code instance, where as workplace settings are applied when a workplace is opened and these settings are stored inside workplace. Workplace settings override users settings.

Adding settings: code > Preferences > Settings > Add settings

Tips & Tricks
Useful Resources