Skip to content

Intro to Command Line Interface

Posted on:March 1, 2024

CLI? Shell? Terminal?

Shell is a program that takes commands from the keyboard and gives them to the operating system to perform. In the old days, it was the only user interface available on a Unix-like system such as Linux. (It’s the out most layer of the OS, thus the name)

Different types (dialects) of shells


Why use the terminal?


Learning Shell Commands

Basic Navigation



Understanding Your File System


Using Flags


Greping and Searching

Flags with parameters


Data piping, redirect & chaining commands



Make Network calls with curl


Package Managers

OS Package Managers

Installs and manages software on your machine


Language specific package managers

Makes managing dependencies easier


Beyond the Basics

Shell Scripting


Plugins and Tools

Lawrence’s CLI setup


Exercises

  1. Navigate to your home directory
  2. List all the files and directories in your current directory
  3. Create a directory called test using mkdir
  4. Change into the test directory
  5. Create a file called file.txt
  6. Rename the file.txt file to result.txt

  1. Download the text from https://raw.githubusercontent.com/ImPrankster/tamid-tech-resources/main/cli/foundation-and-earth to novel.txt
  2. Search for the word robot (case ignored) in novel.txt, and output to result.txt