在 rails 中显示挂起的迁移 [英] Show pending migrations in rails

查看:34
本文介绍了在 rails 中显示挂起的迁移的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有一个 rake 任务显示 Rails 应用程序中的待处理迁移?

Is there a rake task that shows the pending migrations in a rails app?

推荐答案

rake db:migrate:status (Rails 3 to 5) or rails db:migrate:status(Rails 5) 将实现这一点.请参阅此提交.

rake db:migrate:status (Rails 3 to 5) or rails db:migrate:status (Rails 5) will accomplish this. See this commit.

up 表示迁移已经运行.down 表示迁移尚未运行.

up means the migration has been run. down means the migration has not been run.

这篇关于在 rails 中显示挂起的迁移的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆