aboutsummaryrefslogtreecommitdiffhomepage
path: root/gbp/config.py
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2015-05-04 18:54:33 +0200
committerGuido Günther <agx@sigxcpu.org>2015-05-05 08:51:45 +0200
commitf22785b525077d8f4cbac1d674b6cb8af6fb28b1 (patch)
treea46004afedf8430c57f88286f01490648b5f2ae1 /gbp/config.py
parent5280d82e2bfaa8723246df0178d67615400a4d78 (diff)
Allow to disable config section deprecations
Config section deprecations can be disabled by setting GBP_DISABLE_SECTION_DEPRECTATION=true in the environment.
Diffstat (limited to 'gbp/config.py')
-rw-r--r--gbp/config.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/gbp/config.py b/gbp/config.py
index 8cfac0d0..dbe56907 100644
--- a/gbp/config.py
+++ b/gbp/config.py
@@ -364,9 +364,10 @@ class GbpOptionParser(OptionParser):
return
parser.read(filename)
- def _warn_old_config(self, oldcmd, cmd):
- gbp.log.warn("Old style config section [%s] found "
- "please rename to [%s]" % (oldcmd, cmd))
+ def _warn_old_config_section(self, oldcmd, cmd):
+ if not os.getenv("GBP_DISABLE_SECTION_DEPRECTATION"):
+ gbp.log.warn("Old style config section [%s] found "
+ "please rename to [%s]" % (oldcmd, cmd))
def parse_config_files(self):
"""