Bash is a shell that exists on all Linux machines and in apple machines also.
You can’t not start it directly, or find any many with bash, to run bash you need to simply run a terminal emulator.
That terminal emulator runs bash inside it.
This video shows where you need to go to open a terminal window inside finder.
What you see when you opened it is what we call bash prompt.
The Prompt is where we can call the bash commands.
All commands should be followed by enter key. This enter key is what forces the machine to read my stings and execute them accordingly.
If the machine does not recognizes my strings as a command it will return an error of command not found.
The prompt can be 100% configurable.
The one that is listed on the video is reconfigured but all the basic is present there.
Lets take a look at the prompt.
In the video you will identify the following things in the command prompt:
- The logged on user
- The name of the machine where the user is logged on
- The path where the user is
- And the command line space.
For that we had to use several commands, the commands will be spoken a bit latter for now I just want to list them and give a introduction.
- cd – stands for Change directory it is used to change from one directory to another.
- pwd – stands for Print Working Directory and it is used to show us where we are.
- ls – stands for list segments and it is used to list files and directories
And you can think of the current working directory as the location you are currently at.
Navigate a bit though your file system using the ” CD ” and ” CD .. ” and the other commands that were used on the video to see where you are, and list contents.
You will have different contents than me for sure.
Make yourself comfortable because this will be very useful for the future.