Scripts
One of the many areas where linux totally outshines windows is the ability
to use scripts. OK, you can use batch files, or install cygwin, but it's considerably easier and
richer under linux. Check out the Advanced Bash Scripting Guide for one
of the many ways of going about scripting under linux.
Here are a collection of scripts that over time have proved useful.
• Colour Chart
This simple script displays a grid of the ANSI colours available for text
highlighting on a terminal. It shows the foreground and background colours, as
wells as the effect of using bold type. Using this script is much easier than
trying to remember all the codes.
• EPS to JPEG converter
This script is a wrapper around ghostscript to make it quicker to convert
eps files to jpegs. It requires that you have the gs command.
• Internet Audio Stream Recorder
This script is basically a wrapper to mplayer. It is used for recording an
internet audio stream to a file, in this case an ogg vorbis file, however, with
a little modification any other format could be used.
The script creates a fifo into which mplayer pipes the audio. The pipe is
fed into oggenc which creates the resulting file. A very handy script if you
want to make a permanent recording of some online audio programme.
|