Chapter #2: Writing and Running Your First Bash Script
In this lesson, weβll walk you through creating your very first Bash script, running it, and learning some helpful terminal tips along the way.

The bash script is a powerful scripting language that every Linux user either wants to master for Linux administration or just as a regular developer needs to know in order to make managing Linux easy and automated.
At first, you may think that it is hard to learn as there are a lot of commands and symbols within the language itself, but in reality, Bash is easy and fun to learn, as you will see the results from the first attempt to learn, unlike other programming languages.
You won't get what you really need to use in other programming languages until a certain point init learning. On the other hand, in Bash, every command you learn gives you an immediate result, and you remember why you need it.
All you need as a beginner is to follow along with every step to get the most benefit. Each command or trick will make your life easier and help you become more productive.
In these lessons, let's learn how to write our first Bash script file, how to execute it, and get some tricks and tips that make writing commands in the terminal simpler and more efficient.
How to Write a Bash Script
We already learned that a Bash script file is just a file where we put a sequence of commands that are combined together to achieve a specific role or task.
Don't be afraid of using the terminal or the shell. Every time you write a command, you will become more familiar with it and see how simple and fun it is.
Letβs now create our very first Bash script!
Step 1: Open the Terminal
The first step is to open your terminal, either using the graphical way by searching for the terminal in the application menu of your distribution or by using the simple key binding Ctrl + Shift + T. It is highly recommended to start using keybindings instead of the mouse, as this will make you faster at performing tasks.
The terminal window will sometimes look different, but how it looks is not really important. The commands are the same; it's just some color and font customization.