From e794b913c8b9eda334f84374e909a550a3c3bd09 Mon Sep 17 00:00:00 2001 From: Peter Rowlands Date: Thu, 21 Apr 2022 16:03:20 +0900 Subject: [PATCH] bump-formula-pr: expose update-python-resources CLI flags --- Library/Homebrew/dev-cmd/bump-formula-pr.rb | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/dev-cmd/bump-formula-pr.rb b/Library/Homebrew/dev-cmd/bump-formula-pr.rb index a463a48f534dc..1d726494c96fc 100644 --- a/Library/Homebrew/dev-cmd/bump-formula-pr.rb +++ b/Library/Homebrew/dev-cmd/bump-formula-pr.rb @@ -78,6 +78,13 @@ def bump_formula_pr_args "or specified ." switch "-f", "--force", description: "Ignore duplicate open PRs. Remove all mirrors if `--mirror` was not specified." + flag "--python-package-name=", + description: "Use the specified when finding Python resources for . "\ + "If no package name is specified, it will be inferred from the formula's stable URL." + comma_array "--python-extra-packages=", + description: "Include these additional Python packages when finding resources." + comma_array "--python-exclude-packages=", + description: "Exclude these Python packages when finding resources." conflicts "--dry-run", "--write-only" conflicts "--dry-run", "--write" @@ -329,8 +336,13 @@ def bump_formula_pr end unless args.dry_run? - resources_checked = PyPI.update_python_resources! formula, version: new_formula_version, - silent: args.quiet?, ignore_non_pypi_packages: true + resources_checked = PyPI.update_python_resources! formula, + version: new_formula_version, + package_name: args.python_package_name, + extra_packages: args.python_extra_packages, + exclude_packages: args.python_exclude_packages, + silent: args.quiet?, + ignore_non_pypi_packages: true end run_audit(formula, alias_rename, old_contents, args: args)