Power of The Shell

Pruthvi SriramPruthvi Sriram
2 min read

What is Shell Scripting

Looking back at the end of the year, shell scripting was the most helpful thing I learned. More than just a way to fiddle with the UNIX and UNIX-based operating systems, The shell is a powerful tool that can be used to create automated scripts and schedule cronjobs, improving usability and efficiency.

It is just a text file containing commands and prompts to communicate with UNIX-based environments. This text file alone gives the essence of libre, allowing users to just literally do anything from simple update commands to automated administrative tasks to even applets.

The thing about shell scripting is that because the shell is like a layer that can be used to work with your computer, basic or advanced it can be a powerful tool that can even burnout your computer or wipe the entire hard disk.

sudo rm -rf /

In the above code, 'rm' is a simple command used to remove or delete files or folders, '-r' makes it remove recursively, and the '-f' forces the whole action. But the '/' indicates the drive and will delete the entire drive if not careful.

The Language wonder

Now the outputs and inputs in the shell code can be piped to or from which is amazing, meaning outputs from any language can be piped into a bash script and be used as an input instead.

In the shell also using some simple operators ( '>') the output of any function or command can be yanked into a text file making logging and storing easier.

Files and folders can be easily manipulated using universal indicators and pointers.

Shell script and be implemented for daily use cases too so it gives a whole new use case for the TUI or the CLI.

Freedom of selection

There are plenty of options for SHELLs all same functionality at the core but with different features which improve the user experience. Some examples are listed below.

  • Fish

    It is a more interactive shell and provides a more user-friendly experience. Its got features like Syntax highlighting, Autosuggestions, Universal variables, etc.

  • Bash

    It's the default shell in most of the UNIX-based operating systems.

  • Zsh

    My personal favorite for how customizable it is. It takes the best of the Bash, Ksh, and Tcsh shells and implements them in a single shell. It also supports themes and plugins.

And more..

Some of my code

https://github.com/ekahPruthvi/gitProfiler

https://github.com/ekahPruthvi/Error.sh

https://github.com/ekahPruthvi/cynical-calibration

1
Subscribe to my newsletter

Read articles from Pruthvi Sriram directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Pruthvi Sriram
Pruthvi Sriram

A techie, Linux Enthusiast an a wannabe Open Source Developer.