Add some useful features to our flags
* No longer dies if there are unknown flags. * Allows you to declare that you will use a flag from another file * Allows you to import new flags at runtime and reparses the original arguments to fill them once they are accessed.
This commit is contained in:
5
nova/tests/declare_flags.py
Normal file
5
nova/tests/declare_flags.py
Normal file
@@ -0,0 +1,5 @@
|
||||
from nova import flags
|
||||
|
||||
FLAGS = flags.FLAGS
|
||||
|
||||
flags.DEFINE_integer('answer', 42, 'test flag')
|
||||
Reference in New Issue
Block a user