Category Archives: Bash

Parsing files and rename …

Sometimes you have to rename files. This can be tiring when we do it manually. Command sed may be helpful in this case. I’ll take a simple example. I will create a working directory called work. We have to create files with the command:

The result should be :

Try these commands to… Read More »

BASH shell scripting tips – part 1 : Working with shell variables.

As we know, we used the following syntax will to create a default script bash. First line: signifies that is the bash script:

Every line and everything after the # is treated as a comment:

A shell variable may be assigned using the following syntax: variable=value_of_variable Example:

Try this command:

Read More »