Programming

Terminal

What is Terminal?

A terminal is the command line under an old name. A line stands on the screen, you type a word, you press Enter, and a program reads that word. Changing a folder, seeing a file's name, starting Python, and writing a Git step happen from here. On Linux this window is often called Terminal. On Windows it can be Command Prompt or PowerShell. A Mac has Terminal too. The window does the same job, but the language you type inside can change. Bash is one of those languages. If the command is not Bash, another program reads it. Closing the window does not delete a file. If the command you typed has finished, the result is already on the disk. A job hidden in a window of buttons is shown by the terminal on one line. That is why a programmer opens it often.

What is Terminal used for?

A terminal is for typing directly the command a button hides. You also see the result in that same window.

  • Changing a folder and seeing a file's name
  • Starting a Python or Git command
  • Reading the text of an error
  • Opening a program that has no button

What can you do with Terminal?

With a terminal you type a word and a program carries out that word. cd changes the folder. ls or dir lists the files. python starts a file. git writes a step. The window does not know these by itself. The program inside knows. If you type a wrong word, the window says it did not understand you. A command that deletes a file is also typed here, so do not rush an unknown line with Enter. A terminal is not an internet site and it is not a programming language. It is the place where a command is typed.

Is Terminal hard to learn?

Opening the window is easy. The difficulty is knowing which folder the command is standing in. If it is the wrong folder, the file is not found and you think the program does not exist. The writing of a path is not the same on Windows and Linux. A capital letter sometimes matters too. A command you copied may contain a name that does not exist on your machine. Do not start an unknown command, especially one that deletes or writes everywhere, on one line.

Advantages and limits

A terminal is fast and shows what a button hides. A mistake is also fast on one line. A window of buttons is calm for a beginner, but some jobs have no button. Learning Bash is not learning the window. First open the window, see which folder you are standing in, then type a short command.

Basic ideas

A terminal is a window. A command is the word inside. Bash is one language of that word.

  • Enter starts the word
  • Closing the window does not delete a file
  • Bash is not the terminal itself
  • A command in the wrong folder does not find the file

A short example

This changes the folder and shows the names there. The window does not type this itself. You type it.

cd layihe
ls

Common questions

  • Are the terminal and Bash the same? No. The terminal is a window. Bash is one of the languages used in that window.
  • Does closing the terminal delete a file? No. The window closes. The result of a finished command stays on the disk.
  • Is there a terminal on Windows? Yes. Command Prompt and PowerShell are windows for the same job. The writing of a command can differ from Linux.