sh -x and sh -v in Linux
While programming shell sometimes you need to find the errors (bugs) in shell script and correct the errors (remove errors - debug). For this purpose you can use -v and -x option w
Read tutorialTHE TUTORIAL LIBRARY
While programming shell sometimes you need to find the errors (bugs) in shell script and correct the errors (remove errors - debug). For this purpose you can use -v and -x option w
Read tutorialThe case statement is good alternative to Multilevel if-then-else-fi statement. It enable you to match several values against one variable. Its easier to read and write.
Read tutorialLoop is executed as long as given condition is true. For e.g..>the for loop program can be written using while loop as:
Read tutorialAs you see the if statement can nested, similarly loop statement can be nested. You can nest the for loop. To understand the nesting of for loop see the following shell script.
Read tutorialThe for loop first creates i variable and assigned a number to i from the list of number from 1 to 5, The shell execute echo statement for each assignment of i. (This is usually kn
Read tutorialAbove program gives error for last run, here integer comparison is expected therefore error like "./elf: [: -gt: unary operator expected" occurs, but still our program notify this
Read tutorialYou can write the entire if-else construct within either the body of the if statement of the body of an else statement. This is called the nesting of ifs.
Read tutorialIf given condition is true then command1 is executed otherwise command2 is executed.
Read tutorialtest command or [ expr ] is used to see if an expression is true, and if it is true it return zero(0), otherwise returns nonzero for false.
Read tutorialif condition which is used for decision making in shell script, If given condition is true then command1 is executed.
Read tutorialWhen Linus Torvalds first developed Linux back in August of 1991, the operating system basically consisted of his kernel and some GNU tools. With the help of others Linus added mor
Read tutorialIf a Linux command accepts its input from the standard input and produces its output on standard output is know as a filter. A filter performs some kind of process on the input and
Read tutorialOne example today. A better developer tomorrow.