🖱️ Step 3: Navigating Linux OS | Betabox

🖱️ Step 3: Navigating Linux OS

Here’s a quick tutorial on how to navigate the Linux operating system.

Back before computers had a desktop, graphical programs used the command line to communicate with the user. Command lines are a mainstay in modern day computers and while most users don’t have a use for them, programmers find them invaluable. The command line allows you to edit files, run code, change settings, start and install programs, and almost anything else you could do with a desktop. In Windows, the command line is called the command prompt, or cmd. On Mac and Linux run computers, it is called the shell.

When you ‘SSH‘ into a Raspberry Pi with PuTTY (an application that implements these protocols and allows you to log into the Command Line of a remote machine), you are accessing the shell with a Secure SHell connection.

To access the command prompt, use the search function of your computer to find the command prompt application on your computer.

The command line can be sent commands by typing them out and pressing enter. Here is a cheat sheet of some command you may encounter:

  • Copy and paste: To copy and paste, use ctrl+shift+c and ctrl+shift+v. You can also right-click on the terminal
  • Get the current directory or folder you are working in (print working directory): pwd
  • List folders in current directory: ls
  • Change directory (open a folder): cd {folder name}. This will open a folder in the current directory. If you want to open a folder in the home directory you need use ~/{foldername}
  • Make a new directory (folder): mkdir
  • Delete a file: rm {file name}
  • Delete a folder: rm -rf {foldername}
  • Run a command as an administrator {some commands need this}: sudo {command}
  • Open a file with text editor: nano {text file}
  • Make an empty file: touch {new file name} OR nano {new file name}
  • Stop script or command: ctrl+c

You do not need to memorize these shortcuts but being familiar with them will help you understand what you will be doing in the next steps.