Configuring Visual Studio Code

Configuring Visual Studio Code Visual Studio Code (VSC) is an open source, freely available code editor and lightweight integrated development environment. It is very user friendly and is commonly used by students at Pennwest Edinboro. VSC is available at https://code.visualstudio.com/ ## Extensions VSC is a very extendable program and programmers should explore these extensions, however, there are a few that are particularly useful for the environment at Pennwest Edinboro. + SSH FS by Kevin Schoofs + C/C++ Extension Pack by Microsoft + Makefile Tools by Microsoft SSH FS provides tools to edit files on one of the servers (prog1 or devweb1) on your local machine (most likely your laptop). It also allows you to open a terminal where you can manipulate files and compile and run programs. The C/C++ and Makefile extensions provide useful tools like syntax highlighting and code completion. ### Installing an extension After you start VSC, you can add an extension by clicking on the extensions icon on the left of the window. ![](extensionsIcon.png alt="The VSC Extensions Icon") Type the name of the extension you want into the search bar, and select install in the corresponding package. ![](makefileTools.png alt="Installing the Makefile Extension") The extension should be installed and ready to use. ### Configuring SSH FS You need to configure the SSH FS extension to use the local machines. To do this 1. Use the extensions icon (see above) to see your installed extensions. 1. Select the manage icon (gear in the lower right of the extension box) 1. Select Settings from the pop up menu. ![](ConfigSSH1.png alt="Starting to edit the SSH extension.") 1. Select***Edit in settings.json*** ![](ConfigSSH2.png alt="Selecting configuration the file to edit." 1. Change the file to match the following: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~json { "sshfs.configs": [ { "name": "prog1", "host": "prog1.cs.pennwest.edu", "root": "/home/dbennett@DC1.PENNWEST.EDU", "username": "dbennett" }, { "name": "devweb1", "host": "devweb1-ssh.cis.pennwest.edu", "root": "/home/dbennett", "username": "dbennett" } ], } ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ __NOTE You will need to change *dbennett* to be your Pennwest user name.__ 1. Save this file, and you should be able to connect to either devweb1 or og1 1 and create and run programs there 1. You should go the SSHFS selector on the left of the window and click on the refresh button for configurations. You may also want to refresh your connections. ![](ConfigSSH3.png alt="Updating the configurations after changing the settings.") You should now be able to open terminals and edit files on the department servers.