File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3434 "**Documentation**: \n - {docs}"
3535)
3636HELP_NOTE = (
37- "If using Fedora CI, refer to `/packit-ci help` instead. "
38- "Refer to `/packit-ci-stg help` if using the staging instance."
37+ "`/packit` commands interact with the opt-in packit jobs "
38+ "(e.g. `propose-downstream`, `pull-from-upstream`). "
39+ "If you are looking for help on Fedora CI jobs "
40+ "(e.g. `scratch-build`, `test rpminspect`, etc.), "
41+ "refer to `/packit-ci` or `/packit-ci-stg`."
3942)
4043HELP_NOTE_FEDORA_CI = (
41- "For default Packit behaviour, refer to `/packit help` instead. "
42- "Refer to `/packit-stg help` if using the staging instance."
44+ "`/packit-ci` commands interact with Fedora CI jobs "
45+ "(e.g. `scratch-build`, `test rpminspect`, etc.). "
46+ "If you are looking for help on the opt-in packit jobs "
47+ "(e.g. `propose-downstream`, `pull-from-upstream`), "
48+ "refer to `/packit` or `/packit-stg`. "
49+ "These assume a `.packit.yaml` configuration file is present in the repo."
4350)
4451
4552KOJI_PRODUCTION_BUILDS_ISSUE = "https://pagure.io/releng/issue/9801"
Original file line number Diff line number Diff line change @@ -241,15 +241,13 @@ def _create_base_parser(
241241 description : str | None = None ,
242242 epilog : str | None = None ,
243243) -> argparse .ArgumentParser :
244- parser = argparse .ArgumentParser (
244+ return argparse .ArgumentParser (
245245 prog = prog ,
246246 description = description ,
247247 epilog = epilog ,
248248 formatter_class = RawTextHelpFormatter ,
249249 add_help = False ,
250250 )
251- parser .add_argument ("--package" , help = "specific package from monorepo to run job for" )
252- return parser
253251
254252
255253def get_comment_parser (
@@ -258,6 +256,7 @@ def get_comment_parser(
258256 epilog : str | None = None ,
259257) -> argparse .ArgumentParser :
260258 parser = _create_base_parser (prog , description , epilog )
259+ parser .add_argument ("--package" , help = "specific package from monorepo to run job for" )
261260
262261 subparsers = parser .add_subparsers (
263262 dest = "command" ,
Original file line number Diff line number Diff line change @@ -273,9 +273,8 @@ def parse_comment(
273273 try :
274274 args = parser .parse_args (commands )
275275 check_target = getattr (args , "check_target" , None )
276- return ParsedComment (
277- command = args .command , package = args .package , check_target = check_target
278- )
276+ package = getattr (args , "package" , None )
277+ return ParsedComment (command = args .command , package = package , check_target = check_target )
279278 except SystemExit :
280279 # tests expect invalid syntax comments be ignored
281280 logger .debug (
You can’t perform that action at this time.
0 commit comments