CT Textbook Site
  

Experiment with a CLI

The CLI on Your Computer

  1. Start a Shell window on your computer:
    • On Microsoft Windows, start a Command Shell or a PowerShell by running cmd.exe or powershell.exe
    • On Mac OS X, start a Terminal Shell by running the Terminal application
    • On Linux, start a BASH Shell by running any terminal window such as Gnome-Terminal
  2. In the Shell window, enter these two commands:
    echo %cd%     (windows: displays current directory path)
    dir           (windows: lists files in the current directory)
    
    pwd           (Mac OS X and Linux: displays current directory path)
    ls -l         (Mac OS X and Linux: lists files in the current directory)