Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev-cmd/bump: add --no-fork switch #16740

Merged
merged 2 commits into from
Feb 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Library/Homebrew/dev-cmd/bump.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ def bump_args
description: "Check only casks."
switch "--installed",
description: "Check formulae and casks that are currently installed."
switch "--no-fork",
description: "Don't try to fork the repository."
switch "--open-pr",
description: "Open a pull request for the new version if none have been opened yet."
flag "--limit=",
Expand Down Expand Up @@ -509,6 +511,8 @@ def retrieve_and_display_info_and_open_pr(formula_or_cask, name, repositories, a
"--message=Created by `brew bump`",
]

bump_cask_pr_args << "--no-fork" if args.no_fork?

system HOMEBREW_BREW_FILE, *bump_cask_pr_args
end

Expand Down
1 change: 1 addition & 0 deletions completions/bash/brew
Original file line number Diff line number Diff line change
Expand Up @@ -443,6 +443,7 @@ _brew_bump() {
--help
--installed
--limit
--no-fork
--no-pull-requests
--open-pr
--quiet
Expand Down
1 change: 1 addition & 0 deletions completions/fish/brew.fish
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,7 @@ __fish_brew_complete_arg 'bump' -l full-name -d 'Print formulae/casks with fully
__fish_brew_complete_arg 'bump' -l help -d 'Show this message'
__fish_brew_complete_arg 'bump' -l installed -d 'Check formulae and casks that are currently installed'
__fish_brew_complete_arg 'bump' -l limit -d 'Limit number of package results returned'
__fish_brew_complete_arg 'bump' -l no-fork -d 'Don\'t try to fork the repository'
__fish_brew_complete_arg 'bump' -l no-pull-requests -d 'Do not retrieve pull requests from GitHub'
__fish_brew_complete_arg 'bump' -l open-pr -d 'Open a pull request for the new version if none have been opened yet'
__fish_brew_complete_arg 'bump' -l quiet -d 'Make some output more quiet'
Expand Down
1 change: 1 addition & 0 deletions completions/zsh/_brew
Original file line number Diff line number Diff line change
Expand Up @@ -498,6 +498,7 @@ _brew_bump() {
'--help[Show this message]' \
'--installed[Check formulae and casks that are currently installed]' \
'--limit[Limit number of package results returned]' \
'--no-fork[Don'\''t try to fork the repository]' \
'(--open-pr)--no-pull-requests[Do not retrieve pull requests from GitHub]' \
'(--no-pull-requests)--open-pr[Open a pull request for the new version if none have been opened yet]' \
'--quiet[Make some output more quiet]' \
Expand Down
2 changes: 2 additions & 0 deletions docs/Manpage.md
Original file line number Diff line number Diff line change
Expand Up @@ -1031,6 +1031,8 @@ formulae, also displays whether a pull request has been opened with the URL.
Check only casks.
* `--installed`:
Check formulae and casks that are currently installed.
* `--no-fork`:
Don't try to fork the repository.
* `--open-pr`:
Open a pull request for the new version if none have been opened yet.
* `--limit`:
Expand Down
4 changes: 4 additions & 0 deletions manpages/brew.1
Original file line number Diff line number Diff line change
Expand Up @@ -1461,6 +1461,10 @@ Check only casks\.
Check formulae and casks that are currently installed\.
.
.TP
\fB\-\-no\-fork\fR
Don\'t try to fork the repository\.
.
.TP
\fB\-\-open\-pr\fR
Open a pull request for the new version if none have been opened yet\.
.
Expand Down
Loading