# Migration flag

**URL:** <https://www.ruby-forum.com/t/migration-flag/147157>\
**Category:** Rails\
**Created:** [August 28, 2008, 9:53pm UTC](https://www.ruby-forum.com/t/migration-flag/147157 "2008-08-28T21:53:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ericgoodwin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c68b51/32.png) [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Post date:** [August 28, 2008, 9:53pm UTC](https://www.ruby-forum.com/t/migration-flag/147157/1 "2008-08-28T21:53:33Z")

</div>

Is there anything wrong with creating an application wide flag to  
signify when code is migrating?

How can I detect if a the environment is currently in migrating mode.  
Does anyone have some methods for this?

---

<div class="post-metadata">

**Author:** ![ericgoodwin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c68b51/32.png) [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Post date:** [August 28, 2008, 10:03pm UTC](https://www.ruby-forum.com/t/migration-flag/147157/2 "2008-08-28T22:03:06Z")

</div>

Hi Aryk,

Aryk G. wrote:

> Is there anything wrong with creating an application  
> wide flag to signify when code is migrating?

I’m not sure what you mean by ‘when code is migrating’. Do you mean  
something like ‘when a migration is in process’? Say a little more  
about  
the problem you’re trying to solve and we might be able to help.

Best regards,  
Bill

---

<div class="post-metadata">

**Author:** ![ericgoodwin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c68b51/32.png) [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Post date:** [August 28, 2008, 11:22pm UTC](https://www.ruby-forum.com/t/migration-flag/147157/3 "2008-08-28T23:22:17Z")

</div>

Yeah, sorry about that.

I meant when an “rake db:migrate” is taking place.

Bill W. wrote:

> Hi Aryk,
> 
> Aryk G. wrote:
> 
> > Is there anything wrong with creating an application  
> > wide flag to signify when code is migrating?
> 
> I’m not sure what you mean by ‘when code is migrating’. Do you mean  
> something like ‘when a migration is in process’? Say a little more  
> about  
> the problem you’re trying to solve and we might be able to help.
> 
> Best regards,  
> Bill
