DEV Community

Cover image for Scripting Series – Part 4 of 8
Alex Enson
Alex Enson

Posted on

Scripting Series – Part 4 of 8

Welcome to part 4 in the series of shell scripting. Today we will look at a script that goes through an array with complex values. Complex values such as spaces, apostrophes, and quotes.

Scripting is the process of writing a set of instructions in a programming or scripting language to automate tasks that would otherwise be done manually. In the context of shell scripting, these instructions are written for the command-line shell, allowing users to perform complex operations - like file management, backups, or software installations - with just a single script execution. It's a powerful tool for saving time and ensuring consistency in system administration and development workflows

Create the script in VIM, complex_list.sh
Image description

Write and save the script in VIM.
Image description

We can check whether it has been created by doing ls -ltrh.
Image description

Give the permission so the script can be executed.
Image description

If we then do a ls –ltrh we can see the script has gained a green colour, meaning that it is now executable.
Image description

Output after executing the script by using the command ./
Image description

Stay tuned, part 5 in the series coming tomorrow!




Connect with me on LinkedIn


#30DaysLinuxChallenge #RedHatEnterpriseLinux
#CloudWhistler #CloudEngineer #Linux
#DevOps #RedHat #OpenSource
#CloudComputing #Automation
#CloudEngineer #SysAdmin #ITSecurity #TechTips #BusinessIT #Leadership

Top comments (0)