Skip to content

Commit 810cf69

Browse files
committed
commit: add --distdir for manifest operations
Resolves: #99 Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
1 parent 472794c commit 810cf69

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

src/pkgdev/scripts/pkgdev_commit.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,16 @@ def __call__(self, parser, namespace, value, option_string=None):
129129
Add a Signed-off-by trailer by the committer at the end of the commit
130130
log message.
131131
132-
For commiting to the Gentoo repository, under GLEP-76, the commiter
132+
For committing to the Gentoo repository, under GLEP-76, the committer
133133
shall certify agreement to the Certificate of Origin by adding
134134
Signed-off-by line containing the committer's legal name.
135135
""")
136+
commit_opts.add_argument(
137+
'-d', '--distdir', type=arghparse.create_dir, help='target download directory',
138+
docs="""
139+
Use a specified target directory for downloads instead of the
140+
configured DISTDIR.
141+
""")
136142

137143
msg_actions = commit_opts.add_mutually_exclusive_group()
138144
msg_actions.add_argument(
@@ -761,7 +767,8 @@ def update_manifests(options, out, err, changes):
761767
# manifest all staged or committed packages
762768
failed = repo.operations.manifest(
763769
options.domain, packages.OrRestriction(*pkgs),
764-
observer=observer_mod.formatter_output(out))
770+
observer=observer_mod.formatter_output(out),
771+
distdir=options.distdir)
765772
if any(failed):
766773
return 1
767774

0 commit comments

Comments
 (0)