Linux Bash History

Bash shell runs in terminals like gnome-terminal, konsole, getty, etc. To make things make easy bash provides some shortcuts and pragmatic operations. Here we will look details about them. History Busy system administrators writes a lot of bash commands. They have no time to write notes about the commands. But...


Linux Bash Input, Output and Redirect

Linux Bash have different ways to run command and get output of the command or redirect the output. In this tutorial we will look different ways to redirect commands output. Writing Multiple Commands Same Line Command line can be terminated with ; to write commands same line

In this...


Linux Bash Arrays and Elements

Creating variable is easy and very useful to make simple applications. If the variable count goes up managing variables becomes pain. Think that if the variables count is higher than 100 how easily can be created, assigned. There is a simpler usage for multiple variables. It is called array. An...


Linux Bash Operators Like Assignment, Plus, Calculation

We can store different type of values in the variables. But just storing values is generally not enough and we need to make some operations with them. In this tutorial we will look different type of operators which will work with variables. Assignment The most used operator and generally underestimated...


Linux Bash If-Else Conditionals

If-Elif operators are used to design flow of the bash script. We can change the flow according to given conditions with If-Elif . If When writing scripts we have a lot of situation to make decision. We solve the questions marks of the scripts with conditionals. For example the simplest one is...


Linux Bash Define, Call Functions

Generally bash commands are executed regularly. So running complex or multiple commands one by one are difficult. Or sometimes we just want to accomplish task with just one command without diving into it and distribute this command. Here are functions to make things very easy. Functions get parameters and execute...


Linux Bash How to Define, Use Shell Variables

Variables are programming part of the bash and very useful. Without variables bash will be very inefficient shell. Variables are used by bash itself, running applications, daemons, X (graphic) server and for a lot of things. Define Variable Defining variables are easy in bash, just variable and data is enough....


Linux Bash Default Environment Variables

While working with Bash environment we generally need some variable data to set and get. Bash shell provides some default values about current user, hostname etc. as environment variable. In this tutorial we will look most popular of them. Get The User Running Script While running bash interactively or non-interactively...


Linux Bash Directories and Changing Current Working Path

A simple shell command echo pof tut consist of command itself followed by arguments, separated by spaces. Also more complex command can be created. Generally simple commands are used and after execution exit status is provided by wait pid.

Directories and Paths While working with bash we use paths, file...

Enjoy this blog? Please spread the word :)