“Foolproof Your Bash Script” – Some Best Practices

I am a DevOps practitioner and a lazy one too, so whenever we come across any task that needs to be repeated, we create a bash script. I have been doing this for a long time and after doing a lot of mistakes, I figured that if we follow some basic rules we can make our script more portable and less prone to failure when semantics...

by Nitin Bhadauria
Tag: bash


Bash script to open a terminal with multiple tabs on Linux start-up

All of the tasks performed by us after system startup such as opening a browser, MySql etc can be automated by following the steps mentioned below : 1. Write a script:- [bash] sleep 1m;gnome-terminal --geometry=150x50 --tab --title="echo" -e "bash -c \"echo "hello";echo "there";exec...

by Nitesh
Tag: bash


Database Backup Script for windows

In one of the project I am working on, the application needs to be deployed on windows server. To take the database backup, I wrote the script which does the following : Takes database dump and copy it to the backup folder. Zip that backup file and rename it to the format "YYYYMMDD_HHMMSS" Removes  all the backups older than 30...

by Amit Jain
Tag: bash