I finally found the answer to this issue after posting the question again with a little more information and a little more background.
Please see it here
Basically following the devise gem code base and parsing out what I did and didn't need
Pergunta
I cannot find out how to have my gem append a column to an existing model/table. My gem needs to check the created_at
attribute of a model, and based on time passed, set an active
column from true
to false
. I'm assuming that, upon install, it will end up needing a
$ rails {gem_name}:install
type call from the terminal to append the active column to the model's table. I don't think that an engine is the way to go because I'm not creating any models in the gem, and the only migration I need is to alter an existing model.
Any links, tutorials or advice will be greatly appreciated.
Solução 2
I finally found the answer to this issue after posting the question again with a little more information and a little more background.
Please see it here
Basically following the devise gem code base and parsing out what I did and didn't need
Outras dicas
It seem you are a beginner. What do you think reading the fine manual on
http://guides.rubyonrails.org/getting_started.html