In my gem (myEngine.rb) I have the following code :
require "myEngine/version"
require "myEngine/models/contact"
require 'rails/generators'
module myEngine
def self.generate_migration
file_name= "migrationSrc.rb"
src_path= "myEngine/migration_files/"+file_name
destination_path= "db/migrate/"+file_name
//
end
end
When I call the method generate_migration I want my gem to copy the migration file to the db/migrate of my application.
Thanks you for your help.