Kyrre Nygård wrote:

> Hello people,
> 
> I'm looking for the best ways to create a line of code beautification
> (reformatting) scripts -- one for C, one for Ruby, one for Bash and
> one for web development languages like XHTML, XML, CSS, PHP and Ajax.
> Whether as frontline warriors or household maids, they would ensure
> proper indentation, linebreaks, spaces, tabs and so forth.
> 
> Can anybody help me?

I have written a relatively primitive Ruby beautifier (written in Ruby) that
probably could be made ten times better if someone cared to expend the
effort:

http://www.arachnoid.com/ruby/rubyBeautifier.html

There are many things it won't do, some of which are mentioned in this
thread. But it reliably indents and reveals the basic program structure.

It's GPL, so someone could take it and run with it. I myself am too lazy.

-- 
Paul Lutus
http://www.arachnoid.com