$ rails g migration rename_season_to_season_id
class RenameSeasonToSeasonId < ActiveRecord::Migration
def change
rename_column :shoes, :season, :season_id
end
end
def change
change_column(:table_name, :column_name, :new_type)
end
class RenameTitleToNameInTasks < ActiveRecord::Migration[6.0]
def up
rename_column :tasks, :title, :name
end
def down
rename_column :tasks, :name, :title
end
end
rails generate migration rename_title_to_name_in_tasks