diff options
-rw-r--r-- | docs/manpages/gbp-dch.sgml | 14 | ||||
-rw-r--r-- | gbp.conf | 2 | ||||
-rw-r--r-- | gbp/config.py | 1 | ||||
-rw-r--r-- | gbp/scripts/dch.py | 9 |
4 files changed, 24 insertions, 2 deletions
diff --git a/docs/manpages/gbp-dch.sgml b/docs/manpages/gbp-dch.sgml index 20400760..f57c5a8a 100644 --- a/docs/manpages/gbp-dch.sgml +++ b/docs/manpages/gbp-dch.sgml @@ -79,6 +79,7 @@ <arg><option>--commit</option></arg> </group> <arg><option>--customizations=</option><replaceable>customization-file</replaceable></arg> + <arg rep='repeat'><option>--dch-opt=</option><replaceable>dch-options</replaceable></arg> <arg><option>--verbose</option></arg> <arg choice="plain"><replaceable><optional>path1 path2</optional></replaceable></arg> </cmdsynopsis> @@ -483,6 +484,19 @@ </para> </listitem> </varlistentry> + <varlistentry> + <term><option>--dch-opt=</option><replaceable>dch-option</replaceable> + </term> + <listitem> + <para> + Pass option to &dch; verbatim. Note that &gbp-dch; invokes &dch; + multiple times and the option is passed to all invocations so not all + &dch; options make sense here. Options may also conflict + with options picked by &gbp-dch;. + </para> + </listitem> + </varlistentry> + </variablelist> </refsect1> <refsect1> @@ -106,6 +106,8 @@ #git-author = True # Customizatons can e.g. be used for line wrapping #customizations=/usr/share/doc/git-buildpackage/examples/wrap_cl.py +# Options to pass to dch verbatim +#dch-opt = ['--mainttrailer', '--noconf'] # Options only affecting gbp pq [pq] diff --git a/gbp/config.py b/gbp/config.py index ca64547f..3c484cdc 100644 --- a/gbp/config.py +++ b/gbp/config.py @@ -116,6 +116,7 @@ class GbpOptionParser(OptionParser): 'compression-level': '', 'create-missing-branches': 'False', 'customizations': '', + 'dch-opt': [], 'debian-branch': 'master', 'debian-tag': 'debian/%(version)s', 'debian-tag-msg': '%(pkg)s Debian release %(version)s', diff --git a/gbp/scripts/dch.py b/gbp/scripts/dch.py index 31231dae..f1b53965 100644 --- a/gbp/scripts/dch.py +++ b/gbp/scripts/dch.py @@ -1,6 +1,6 @@ # vim: set fileencoding=utf-8 : # -# (C) 2007, 2008, 2009, 2010, 2013, 2015 Guido Guenther <agx@sigxcpu.org> +# (C) 2007,2008,2009,2010,2013,2015,2017 Guido Guenther <agx@sigxcpu.org> # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or @@ -279,7 +279,7 @@ def process_options(options, parser): if options.force_distribution: dch_options.append("--force-distribution") - return dch_options + return dch_options + options.dch_opts def process_editor_option(options): @@ -388,6 +388,11 @@ def build_parser(name): dest="commit_msg") parser.add_option("-c", "--commit", action="store_true", dest="commit", default=False, help="commit changelog file after generating") + parser.add_config_file_option(option_name="dch-opt", + dest="dch_opts", action="append", + help="option to pass to dch verbatim, " + "can be given multiple times", + metavar="DCH_OPT") help_msg = ('Load Python code from CUSTOMIZATION_FILE. At the moment,' ' the only useful thing the code can do is define a custom' |