Preface: For programming in this class, you will want to have good tools. Good tools make programming easier, and let you focus on the (more fun and interesting) content. You will also need to have tools to work with GIT for source control as this will be our mechanism for handing in assignments.
Some ideas on how to install the recommended tools (on Windows) are provided at Installing software that you need.
Overview of Programming Tools for CS559
The requirements (details below):
- Either Firefox or Chrome for a web browser to run programs
- Some GIT client that talks to GitHub
- Some local server to test things out on your machine
The optional (but recommended) things (details below):
- A type checker and/or linter
- A good debugger
- An IDE that integrates 1 and 2
- An SSH key manager so you don’t need to type your password all the time when using GitHub
You may use any tools that works for you. Since we assume that you are using your own computer(s), it is your responsibility to set these things up and learn to use them. We strongly recommend you get things set up the first week in class. Spend time early in the semester to master the tools!
We recommend (and can provide some help with):
- Installing the command line GIT tools, and optionally a visual client (SourceTree)
- Visual Studio Code (VSCode) as an IDE
- LiveServer (inside of VSCode) and Node http-server for a local server
Some details follow.
All your programs will run in a web browser.
Importantly, our programs (the framework and example code for class) must run in your web browser, and your programs (assignments you turn in) need to run in our web browser. In the ideal world, everything is compatible. In practice, it’s safest to try to run the same web browser.
A web browser is a personal choice, so we don’t want to dictate which one to use. We will make sure that our programs that we give to you run in both Firefox and Chrome. For grading, we will have both Firefox and Chrome available. We ask that you tell us which one you tested your program with.
See the GIT page for more information on GIT in CS559.
You will need to work with the GIT source control system. The default way is to install the command line tools, which are available for all platforms. We recommend that you have some familiarity with the command line tools.
In theory, you can do everything via the GitHub web page: download the repo as a ZIP file, upload the files you changed, etc. While this is OK for small fixes, you will not want to do this for your class assignments.
Visual interfaces for GIT can be helpful, and make many tasks easier. I use SourceTree because it’s free, cross-platform, and works for both GIT and Mercurial (and I switch back and forth a lot). The ability to do GIT and Mercurial isn’t so important for this class.
Some IDEs integrate support for source control. Learning to use this can be convenient.
Setting up public keys to connect to GitHub is really convenient – it saves you from typing your password all the time. On windows, this is a little tricky (see the Installing software that you need page). The GitHub Guide should be sufficient for a Mac.
Editors and IDEs
Using a Basic Text Editor
You can probably get by in this class with a basic text editor (Notepad++, Vim, etc.). Almost all of these offer some features for programming (like coloring and checking for basic syntax things). However, more specialized tools can be helpful – helping you work with larger programs (across files), providing more linguistic support, etc.
Atom seems like a basic text editor. However, since it is extensible and has an active user community, it gets a lot of fancy features.
I have started to use Atom as my basic text editor – it has some features that I really like (e.g., good handling of Markdown). I have not tried it for programming.
WebStorm / PyCharm
JetBrains is a company that sells “industrial strength” programming tools. They sell them (they are not free). However… they have “free” editions, and they will provide academic licenses that let you get the full “pro” versions of the tools for free.
Visual Studio Code
The features are really helpful for learning. They catch beginner mistakes. Tooltips that pop up when you look at a function call give you documentation which saves you from having to remember what all the functions are (and having to do a web search each time you want to do something).
See the Visual Studio Code and CS559 page for more thoughts on VSCode for CS559, and help getting started.
Local Web Server
Even though your files are on your computer, the web browser won’t just open them: for security reasons, the web browser disallows doing things with files directly – it wants things to be provided by a web server. Therefore, you need to run a web server on your computer (locally) so that the web browser can read the files on your disk.
Here are three options (there are certainly others):
Use the “http-server” that is part of Node. This requires that you have Node installed (see below). This has useful features like being able to turn off caching so file changes are seen instantly. You probably want to use
Use the simple server that is part of Python. This requires that you have Python installed. The method for using it depends on the version of Python.
Use “live server” that is part of Visual Studio Code. This is really convenient when you are editing a project in Visual Studio Code, but less convenient to just start something up. You probably want to have an option besides this one. Documentation on live server is https://ritwickdey.github.io/vscode-live-server/.
If you use Visual Studio Code, you will probably want to have Live Server (since it is very convenient), but you will also want to have a stand alone option for running programs outside of VSCode.
The graders will use the first option (http-server) for grading. It should be equivalent to second.
Remember: using a local web server requires you to (1) have it installed correctly; (2) start the server running in the correct directory; and (3) pointing your web browser to the right place. Everyone’s configuration is always slightly different, but (for example) when I use
http-server, I need to (1) go to the directory I am working in with my
.html files in a command window, (2) type
http-server -c-1 (I need the option to turn off caching), and go to “http://127.0.0.1:8080/index.html” in my web browser (
http-server tells me this link when I run it).
If you’re using VSCode with live server (recommended), don’t forget to start the server.
Some things you probably want to have:
http-server – See Local Web Server above.
If you use VSCode, you’ll want to have Node installed since VSCode will use Node and npm to do some of its magic such as getting type inference information.
Type Checkers and Linters
The best part about these tools is that they are built into the IDEs (especially Visual Studio Code). While you type, it tells you problems in your program – before you run it.
Markdown is a convention for writing stylized text as plain text. As far as class goes, you can treat a “.md” file as a plain text (.txt) file. The “markdown” elements should be obvious (such as **two asterisks** for bold text, or beginning a line with a # to create a heading).
For class, you are not required to write using any markdown. We will give you Markdown files, but you can just add plain text.
If you use an editor like Atom or Visual Studio Code, it will color and style your markdown.
If you want to learn about markdown (and don’t already know about it), check out the WikiPedia page or the original author’s page. There are many resources on the web including this cheatsheet.
For class, you won’t need a program that converts Markdown to HTML or PDF – but you are welcome to use it. Markdown conversion is built into GitHub (although we won’t use that feature).