Skip to content

Commit 27e25fb

Browse files
dmachmcepl
authored andcommitted
Change 'git-obs pr dump' to produce directories that match the specified pull request IDs
1 parent 3fcc00c commit 27e25fb

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

osc/commands_git/pr_dump.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,12 @@ def init_arguments(self):
2424
self.add_argument(
2525
"--subdir-fmt",
2626
metavar="FMT",
27-
default="{pr.base_owner}/{pr.base_repo}/{pr.number}",
27+
default="{owner}/{repo}/{number}",
2828
help=(
2929
"Formatting string for a subdir associated with each pull request\n"
30-
"(default: '{pr.base_owner}/{pr.base_repo}/{pr.number}')\n"
30+
"(default: '{owner}/{repo}/{number}')\n"
3131
"Available values:\n"
32+
" - 'owner', 'repo' and 'number' parsed from the specified pull request ID\n"
3233
" - 'pr' object which is an instance of 'osc.gitea_api.PullRequest'\n"
3334
" - 'login_name', 'login_user' from the currently used Gitea login entry"
3435
),
@@ -64,6 +65,9 @@ def run(self, args):
6465
continue
6566

6667
path = args.subdir_fmt.format(
68+
owner=owner,
69+
repo=repo,
70+
number=number,
6771
pr=pr_obj,
6872
login_name=self.gitea_login.name,
6973
login_user=self.gitea_login.user,

0 commit comments

Comments
 (0)