BiTree
  • Search For Lessons
  • Curriculum
  • Pricing
  • For Educators
  • Become a Tutor
  • About
  • Contact
Log InGet Started

Questions, concerns, bug reports, or suggestions? We read every message, write to us at [email protected].

More ways to reach us →
BiTree

Live coding lessons for aspiring developers and security professionals.

[email protected]

(201) 785-7951

Mon–Fri, 9 AM–5 PM EST

Learn

  • Search For Lessons
  • Curriculum
  • Pricing

Company

  • About
  • For Educators & Schools
  • Become a Tutor
  • Contact Us

Legal

  • Terms of Service
  • Privacy Policy
© 2026 BiTree. All rights reserved.
Curriculum/Web Development/Introduction to the Terminal and Linux
35 minBeginner

Introduction to the Terminal and Linux

After this lesson, you will be able to: Navigate the file system, manage files, and run scripts from the terminal using the most common Unix commands.

Almost every developer tool, git, npm, Python, deployment commands, is run from the terminal. This lesson covers the handful of commands you'll actually use every day, and how to use the in-browser editor.

Prerequisites:Python Functions and Automation

What is the terminal, really?

The terminal is a text-based way to talk to your computer. Instead of clicking icons, you type commands. On Mac and Linux it's called Terminal; on Windows it's PowerShell or the WSL shell. The commands in this lesson are the Unix-style ones used everywhere except plain Windows cmd.

Diagram coming soon!

Side-by-side comparison of GUI file explorer (folders, icons) and a terminal window (text prompt with ls and cd commands)

Navigation commands

These are the four you will use constantly.

tsx
pwd # print working directory (where am I?)
ls # list files in current directory
ls -la # list everything, with details
cd projects # change directory into projects
cd .. # go up one level
cd ~ # go to your home directory

Creating and managing files

These commands create, copy, move, and remove files.

tsx
mkdir my-site # make a directory
touch index.html # create empty file
cp index.html backup.html # copy
mv backup.html old.html # move (or rename)
rm old.html # delete file
rm -r my-site # delete folder + contents

⚠️ Warning, rm has no undo

Unlike the GUI trash, files removed with rm are gone. Always double-check the path before pressing Enter, especially with rm -rf.

Try it: make a project folder from the shell

Use the Shell tab in your editor (or your local terminal) to run these in order.

  1. 1

    Type pwd and read the output

  2. 2

    Run mkdir bitree-practice and then cd bitree-practice

  3. 3

    Create three files: touch hello.py notes.txt readme.md

  4. 4

    Run ls -la to confirm they exist

  5. 5

    Write a quick Python file with echo "print('hi')" > hello.py and run it with python hello.py

Bonus: chaining and piping

The | (pipe) feeds the output of one command into another. The > redirects output to a file.

tsx
ls -la > files.txt # write directory listing to a file
cat files.txt | wc -l # count the lines
Quick Check

Which command shows you the path of the directory you're currently in?

Pick the one that prints your location.

Sign in and purchase access to unlock this lesson.

Sign in to purchase
←Python Functions and Automation
Back to Web Development
How the Web Works→