VS Code is a free, open source, cross-platform, modern editor for code and text documents. It is developed by Microsoft.
It has Git support built in. A large ecosystem of extensions provide support for many programming languages, file formats, and editing tasks. Of particular use in the MOAD group are:
the Python extension that includes support for conda environments and the ability to edit Jupyter notebooks directly in VS Code
the Remote - SSH extension that enables you to use all of the features of VS Code on directories and files located on remote machines including the Waterhole machines, salish, and the Alliance HPC clusters.
Remote - SSH Extension Notes
If you use the Remote - SSH extension you should increase the connection timeout setting because
salishand some of the Waterhole workstations take >30 seconds to establish ssh connections. You can change that setting by using the menu to open the settings view: File > Preferences > Settings and using the search bar at the top of the view to find
remote ssh connect timeout. Changing the value from the default of 15 seconds to 45 seconds should ensure successful connections to
salishand the Waterhole workstations that are slow to connect.
Extensions that you want to use on the remote machine have to be installed have to be installed there. When you have a Remote - SSH session running, the Extensions sidebar shows extensions that you have installed locally in a LOCAL - INSTALLED list. If an extension can be installed for remote use a button like Install in SSH: salish should be available to trigger the remote installation.
Extensions installed on the remote host show in a list with a name like SSH: SALISH - INSTALLED.
So, to use Python and Jupyter in Remote - SSH connected to
salishyou will need to click the Install in SSH: salish in the Python extension tile in the Extensions sidebar. If you have the Python extension installed locally, you should be able to find its tile in the LOCAL - INSTALLED list. Otherwise, look for it in the RECOMMENDED list, or use the search box at the top of the Extension sidebar to find it.
All of these extensions can be installed from the Extensions sidebar. The links included below are so that you can confirm that you are installing the recommended one because there are many, many extensions with very similar names.
- Microsoft’s Python Extension
Includes Jupyter support and many other features
- Microsoft’s Jupyter Notebook Renderers
Renderers for various image/graph formats output in Jupyter notebooks
- Microsoft’s Remote SSH Extension
Uses ssh to open any directory/folder on a remote machine so that its files can be edited in VS Code.
Includes an editing mode for ssh configuration files.
Enhanced Git functionality and repository visualization
- Code Spell Checker
A basic spell checker that works well with code and documents
A clipboard that remembers your last 200 copy/cut fragments
- Modern Fortran
Syntax highlighting, etc. for Fortran
- Rainbow CSV
Highlight in colour the columns of CSV and similar file types, and other helpers for working with those types of files
- reStructuredText Syntax highlighting
Syntax highlighting and document symbols for reStructuredText
Display PDF files in VS Code