How red Texas became a model for green energy