update (1/28/2013)
The CLI format of the generate command for models will be kept the same except for one change. The second argument that specified the adapter type is now required. Before you could do this:
alloy generate model myModel col1:text col2:integer
and it would automatically use the sql adapter. To avoid confusion, it is now required that you explicitly list the adapter type, like this:
alloy generate model myModel sql col1:text col2:integer
*NOTE:* At the time of this update, this will have no adverse effect on the TiStudio integration as TiStudio always explicitly lists the adapter type. Also, there appears to be no reference to the automatically assigned adapter type in the docs.
original
Currently 2 of the 3 adapters for which models can be generated (properties and localStorage) abide by a similar format:
alloy generate model NAME col1:type1 col2:type2 ...
the sql adapter however behaves slightly differently if you specify the "sql" adapter explicitly in the argument list:
alloy generate model NAME sql col1:type1 col2:type2 ...
This will create a sql adapter, and will only create a migration (necessary for execution) if the "sql" is put in there explicitly. Also, since the sql adapter generation is not uniform with the other commands, it causes issues when generating models for sql through TiStudio, as detailed in ALOY-375.
We need to create a standard, uniform method for creating models based on adapters. Anything that deviates from the standard should be captured in options/flags, not additional arguments. For example:
alloy generate model MyModel col1:string col2:int --adapter sql
relevant changes in the *update* section of the description