Browse Resources

Placement Partners

  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
  • JoomlaWorks Simple Image Rotator
Scripting
File Indirection | Print |  Tell-a-friend

In continuation to our discussion on scripting, in this article we shall discuss a couple of more shell commands and the power of file indirection. The ‘cat’ command is a short form for concatenation, which is its basic functionality. This command prints the concatenated file in the standard output.

Read more...
 
Shell Commands | Print |  Tell-a-friend

In our previous month's article on scripting, we discussed the importance of regular expressions. But the question is, can the regular expressions alone make the scripting powerful? The answer is No. Then how can we make our scripts really powerful? It is indeed the core set of commands, along with simple and easy file operations, that imparts the functionality to scripting and makes it powerful.

Read more...
 
Regular expressions | Print |  Tell-a-friend

No matter how beautiful and advanced the GUIs and window managers are, the real power of Linux remains in automation through the command line. Automation means having a program perform a task without any manual intervention.

Read more...
 
Variables & Constructs | Print |  Tell-a-friend

Till now in our scripting series, we have talked about the regular expressions, commands, and file indirection. Let us now take an analogy. If a script can be compared to a human body and scripting to life, what we have talked, till now, are sense organs (making life more meaningful and powerful), heart (driving the life), and hands (giving the movement), respectively. So, then what is the brain of scripting - the logic part? Yes, it is none other than its constructs. Commands are the heart but we need the constructs to control them. And to assist them, we have the memory components called variables to store various information . Unlike the normal programming world, in the scripting world, we do not have a concept of type to variables. They are just free flowing. You may assign anything to them and interpret them the way you want. This promotes ease of expression. For example, XYZ=5324, XYZ="5234", XYZ='5234', all mean the same thing. To access the value in the variable, we write ${}. So, to print the value in the variable XYZ, we type: echo ${XYZ}. echo is an in-built shell command, which means there is no external executable for echo, but is part of the shell executable. Contrast it with say 'ls' or 'cat'. We will be discussing more advanced topics like built-in commands, in our forthcoming articles.

Read more...