Introducing Cows
Cows is a scripting language whose main goal is to make the creation and updating of a web site faster, more flexible and less prone to errors without relying on server-side technologies (scripting languages, web server extensions etc.).
The idea behind this is that server-side technology should only be used to add dynamic features. Nowadays, many sites rely on it also to make site administration easier - even when contents are static - resulting in useless server overwork.
Of course, with the continuous growth of CPUs' power, and the price for dynamic hosting decreasing, very few people think about performances. I tend to agree with this view: before optimizing something I ask myself if the time needed couldn't be used better. However, I don't think that using Cows instead of server side technology is much time-consuming, and even mixing up Cows for static parts and another technology for dynamic ones is very easy.
Moreover, static pages have some other advantages over dynamically created ones:
- static pages, unlike dynamic ones, can be cached by users' browsers and by proxy servers, saving server bandwith;
- you can create your sites without installing a web server and a scripting language extension module, or an application server;
- if you're part of a team you can easily allow other people to see your work by sending them a bunch of HTML files, without asking them to install a web server and other tools
- you can distribute your site on a CD-ROM or allow users to download a compressed archive and browse it later;
- your site can be easily mirrored;
- you can perform strict checks on unexpected situations; using a static scripting language in conjunction with an automatic build system (e.g. Make), errors (if any) will be shown without needing to test the whole site, and you won't build other work upon them;
- you can freely generate programmatically every element (CSS, image dimensions etc.) without worrying about loss of performances;
- your sites will be much more secure if you evaluate some conditions at build time and not upon each request.
G-Cows' manual will provide a deeper analysis of these advantages.
But most of all, Cows allows to use all your favorite Unix tools while creating a site: you can traverse the whole directory tree with `find', extract informations with `grep', build complex pipelines and so on...
You can also include external scripts and programs written in every language whose interpreter or compiler is installed on your machine. Some tasks can be very easy to accomplish with a small shell script; other may require more complex languages.
Even if you use a server side scripting language, you can still appreciate Cows for every task not relying on dynamic change of your site's contents. I actually use Cows, PHP, custom Apache modules and application server technology.