I have to agree with some of the comments here particularly on the principal on version control however and at the risk or creating some controversy, I would question the value of the solution provided other than it fitted exactly what one person required and it managed to generate some discussion.
Phil was spot on with recommending that SMO was the way to go and while I agree with that for this particular problem my underlying point is that the solution to a problem should really be based on sound technical knowledge of the tool set and the most appropriate elements of that tool set to be used to provide the solution.
Powershell was also mentioned and this in conjunction with SMO/SQLPSX can give you a scripter in one line of code. You cant get much simpler than that and while not very useful as it stands it does serve as an example of the value in knowing what is available.
-- Script all tables in the adventureworks database on the default instance on the local server
Get-SqlDatabase "(localserver)" "adventureworks" | Get-SqlTable | Get-SqlScripter
Articles like this just make me question just how much knowledge the writer has with the tool set we all use on a day to day basis.