Text Editors
First what is a text editor?
There are a ton of text editors available for coders, or aspiring coders like ourselves to choose from.
A text editor is a piece of software that you download and install on your computer, or you access online through your web browser, that allows you to write and manage text, especially the text that you write to build a web site. The text editor has to be one of the most important tools you can use as an aspiring web developer. Choosing A Text Editor by The Older Coder
What makes one text editor better than another?
For the most part it can really depend on the coder and what features they need the editor to possess for the coding project they have to perform. I can see where in certain environments such as schools with a focus on software engineering, or companies that produce software, may require students or employees to have a specific text editor for one feature or another. Those features can be essential or nice-to-have’s. Some of those features are:
- Code completion: a coding insight feature making it easier and faster for a programmer to complete their code.
- Emmett: allows coders working in CSS & HTML to save developers time and less typing due to a shorthand code which is interpreted by the text editor. For VS Code this is built in, for other text editors may require installation as an extension.
- Syntax highlighting: takes the text a programmer types, and makes it more noticeable by colorizing the text depending on what type of code it is. These colors can often be adjusted by the programmer.
- Themes: will allow a programmer to change the color of the background of the text editor, the series of colors in the text, & sometimes themes will affect other aspects of text editing. Different combination of colors can to be easier on the eyes, therefore finding a theme that reduces eye strain and fatigue makes for a more productive coder.
What text editors are available?
Text editors available via their computer:
- Text Edit (Mac based)
- Notepad (Windows based)
- Gedit (Linux based - Gnome desktops only)
- Vim (Almost all Linux distros)
Text editors via a third party:
- Notepad++ (Windows only)
- BB Edit (Mac only)
- Visual Studio Code or VS Code (Windows, Mac, and Linux)
- Atom (Windows, Mac, and Linux)
Using The Terminal
Opening The Terminal
- On Mac -> Is the key combination ‘command + space’ which will bring up Spotlight, then start typing Terminal and it will soon show up.
- On Linux -> ‘Right-click’ on the desktop and there may be an option ‘Open in terminal’.
- On Windows -> With the intentions to remotely log into another machine then an SSH client is needed. Putty is often utilized.
The Shell & Bash
Shell: a part of the operating system that defines how the terminal will behave and look after executing commands.
Bash (Bourne again shell): The most common shell.
Paths
- ~ (tilde) - a shortcut for the home directory.
- . (dot) - a reference to the current directory.
- .. (dotdot)- a reference to the parent directory.
Commands
pwd
: print working directoryls
: list the contents of the current directoryls -a
: will show all contents and hidden files & foldersclear
: clears the terminal windowmkdir
: make directorymkdir (pass the name of the folder)
- AVOID spaces and capital letterscd
: change directorycd ..
: moves to the directory above (however many levels you want to move - it is that number plus 1 EXAMPLE four levels = 5 dots)touch
: will create a new filetouch (pass the name of the file to be created)
: EXAMPLE touch readme.mdcode .
: Will open VS Code in that foldertree
: provide a visual display of file structure