Shell scripts and me!!

Recently I am trying out some shell scripting stuffs……its very flexible and damn powerful. I also tried some very simple ones…

One is as follows:

#!/bin/bash
clear
while true
do

df -a
sleep 2
clear

done

This allows one to constantly monitor the disk space while running install, updates, backups etc. I also tried another for generating fibonacci series:

#!/bin/bash
x=0
y=1
echo $x
echo $y
for i in 1 2 3 4 5
do

let 'x=x+y'
echo $x
let 'y=x+y'
echo $y

done

That’s just the beginning…I’m exploring more about shell scripting. This accompanied with a programming language can work wonders. I’m just loving it…

Advertisements

Comments are closed.