forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
backport: bitcoin#17786, #24611, #25934, #26298, #26508, #26545, #26561, #26569, #26609, partial #26238 #7648
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
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
067ea04
Merge bitcoin/bitcoin#17786: refactor: Nuke policy/fees->mempool circ…
knst f457378
Merge bitcoin/bitcoin#26508: RPC/Blockchain: Minor improvements for s…
knst bab1b8c
Merge bitcoin/bitcoin#26545: test: Remove unused sanitizer suppressions
knst f847167
Merge bitcoin/bitcoin#26561: fuzz: Move-only net utils
knst 1b36b12
Merge bitcoin/bitcoin#26569: p2p: Ensure transaction announcements ar…
knst e7f4aca
partial Merge bitcoin/bitcoin#26238: clang-tidy: fixup named argument…
knst 77b5546
Merge bitcoin/bitcoin#26609: refactor: Move `txmempool_entry.h` --> `…
knst bca2628
Merge bitcoin/bitcoin#26298: refactor: Move src/interfaces/*.cpp file…
knst c9b7094
Merge bitcoin/bitcoin#24611: Add fish completions
knst f0d6600
Merge bitcoin/bitcoin#25934: wallet, rpc: add `label` to `listsincebl…
knst File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,99 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dash-cli --no-files | ||
|
|
||
| function __fish_dash_cli_get_commands_helper | ||
| set --local cmd (commandline -oc) | ||
|
|
||
| # Don't return commands if '-help or -?' in commandline | ||
| if string match --quiet --regex -- '^-help$|^-\?$' $cmd | ||
| return | ||
| end | ||
|
|
||
| # Strip help cmd from token to avoid duplication errors | ||
| set --local cmd (string match --invert --regex -- '^help$' $cmd) | ||
| # Strip -stdin* options to avoid waiting for input while we fetch completions | ||
| # TODO: this appears to be broken when run as tab completion (requires ctrl+c to exit) | ||
| set --local cmd (string match --invert --regex -- '^-stdin.*$' $cmd) | ||
|
|
||
| # Match, format and return commands | ||
| for command in ($cmd help 2>&1 | string match --invert -r '^\=\=.*' | string match --invert -r '^\\s*$') | ||
| echo $command | ||
| end | ||
| end | ||
|
|
||
| function __fish_dash_cli_get_commands | ||
| argparse 'nohelp' 'commandsonly' -- $argv | ||
| set --local commands | ||
|
|
||
| # Exclude description, exclude help | ||
| if set -q _flag_nohelp; and set -q _flag_commandsonly | ||
| set --append commands (__fish_dash_cli_get_commands_helper | string replace -r ' .*$' '' | string match --invert -r 'help') | ||
| # Include description, exclude help | ||
| else if set -q _flag_nohelp | ||
| set --append commands (__fish_dash_cli_get_commands_helper | string replace ' ' \t | string match --invert -r 'help') | ||
| # Exclude description, include help | ||
| else if set -q _flag_commandsonly | ||
| set --append commands (__fish_dash_cli_get_commands_helper | string replace -r ' .*$' '') | ||
| # Include description, include help | ||
| else | ||
| set --append commands (__fish_dash_cli_get_commands_helper | string replace ' ' \t) | ||
| end | ||
|
|
||
| if string match -q -r '^.*error.*$' $commands[1] | ||
| # RPC offline or RPC wallet not loaded | ||
| return | ||
| else | ||
| for command in $commands | ||
| echo $command | ||
| end | ||
| end | ||
| end | ||
|
|
||
|
|
||
| function __fish_dash_cli_get_options | ||
| argparse 'nofiles' -- $argv | ||
| set --local cmd (commandline -oc) | ||
| # Don't return options if '-help or -?' in commandline | ||
| if string match --quiet --regex -- '^-help$|-\?$' $cmd | ||
| return | ||
| end | ||
| set --local options | ||
|
|
||
| if set -q _flag_nofiles | ||
| set --append options ($cmd -help 2>&1 | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match --invert -r '^.*=$') | ||
| else | ||
| set --append options ($cmd -help 2>&1 | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match -r '^.*=$') | ||
| end | ||
|
|
||
| for option in $options | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
| # Add options with file completion | ||
| # Don't offer after a command is given | ||
| complete \ | ||
| --command dash-cli \ | ||
| --no-files \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_cli_get_commands --commandsonly)" \ | ||
| --arguments "(__fish_dash_cli_get_options)" | ||
| # Enable file completions only if the commandline now contains a `*.=` style option | ||
| complete --command dash-cli \ | ||
| --condition 'string match --regex -- ".*=" (commandline -pt)' \ | ||
| --force-files | ||
|
|
||
| # Add options without file completion | ||
| # Don't offer after a command is given | ||
| complete \ | ||
| --command dash-cli \ | ||
| --no-files \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_cli_get_commands --commandsonly)" \ | ||
| --arguments "(__fish_dash_cli_get_options --nofiles)" | ||
|
|
||
| # Add commands | ||
| # Permit command completions after `dash-cli help` but not after other commands | ||
| complete \ | ||
| --command dash-cli \ | ||
| --no-files \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_cli_get_commands --commandsonly --nohelp)" \ | ||
| --arguments "(__fish_dash_cli_get_commands)" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dash-qt --no-files | ||
|
|
||
| # Extract options | ||
| function __fish_dashqt_get_options | ||
| argparse 'nofiles' -- $argv | ||
| set --local cmd (commandline -opc)[1] | ||
| set --local options | ||
|
|
||
| if set -q _flag_nofiles | ||
| set --append options ($cmd -help-debug | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match --invert -r '^.*=$') | ||
| else | ||
| set --append options ($cmd -help-debug | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match -r '^.*=$') | ||
| end | ||
|
|
||
| for option in $options | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
|
|
||
| # Add options with file completion | ||
| complete \ | ||
| --command dash-qt \ | ||
| --arguments "(__fish_dashqt_get_options)" | ||
| # Enable file completions only if the commandline now contains a `*.=` style option | ||
| complete -c dash-qt \ | ||
| --condition 'string match --regex -- ".*=" (commandline -pt)' \ | ||
| --force-files | ||
|
|
||
| # Add options without file completion | ||
| complete \ | ||
| --command dash-qt \ | ||
| --arguments "(__fish_dashqt_get_options --nofiles)" | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,65 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dash-tx --no-files | ||
|
|
||
| # Modified version of __fish_seen_subcommand_from | ||
| # Uses regex to detect cmd= syntax | ||
| function __fish_dash_seen_cmd | ||
| set -l cmd (commandline -oc) | ||
| set -e cmd[1] | ||
| for i in $cmd | ||
| for j in $argv | ||
| if string match --quiet --regex -- "^$j.*" $i | ||
| return 0 | ||
| end | ||
| end | ||
| end | ||
| return 1 | ||
| end | ||
|
|
||
| # Extract options | ||
| function __fish_dash_tx_get_options | ||
| set --local cmd (commandline -oc)[1] | ||
| if string match --quiet --regex -- '^-help$|-\?$' $cmd | ||
| return | ||
| end | ||
|
|
||
| for option in ($cmd -help 2>&1 | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=') | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
| # Extract commands | ||
| function __fish_dash_tx_get_commands | ||
| argparse 'commandsonly' -- $argv | ||
| set --local cmd (commandline -oc)[1] | ||
| set --local commands | ||
|
|
||
| if set -q _flag_commandsonly | ||
| set --append commands ($cmd -help | sed -e '1,/Commands:/d' -e 's/=/=\t/' -e 's/(=/=/' -e '/^ [a-z]/ p' -e d | string replace -r '\ \ ' '' | string replace -r '=.*' '') | ||
| else | ||
| set --append commands ($cmd -help | sed -e '1,/Commands:/d' -e 's/=/=\t/' -e 's/(=/=/' -e '/^ [a-z]/ p' -e d | string replace -r '\ \ ' '') | ||
| end | ||
|
|
||
| for command in $commands | ||
| echo $command | ||
| end | ||
| end | ||
|
|
||
| # Add options | ||
| complete \ | ||
| --command dash-tx \ | ||
| --condition "not __fish_dash_seen_cmd (__fish_dash_tx_get_commands --commandsonly)" \ | ||
| --arguments "(__fish_dash_tx_get_options)" \ | ||
| --no-files | ||
|
|
||
| # Add commands | ||
| complete \ | ||
| --command dash-tx \ | ||
| --arguments "(__fish_dash_tx_get_commands)" \ | ||
| --no-files | ||
|
|
||
| # Add file completions for load and set commands | ||
| complete \ | ||
| --command dash-tx \ | ||
| --condition 'string match --regex -- "(load|set)=" (commandline -pt)' \ | ||
| --force-files |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dash-util --no-files | ||
|
|
||
| # Extract options | ||
| function __fish_dash_util_get_options | ||
| set --local cmd (commandline -opc)[1] | ||
| set --local options | ||
|
|
||
| set --append options ($cmd -help 2>&1 | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=') | ||
|
|
||
| for option in $options | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
| # Extract commands | ||
| function __fish_dash_util_get_commands | ||
| set --local cmd (commandline -opc)[1] | ||
| set --local commands | ||
|
|
||
| set --append commands ($cmd -help | sed -e '1,/Commands:/d' -e 's/=/=\t/' -e 's/(=/=/' -e '/^ [a-z]/ p' -e d | string replace -r '\ \ ' '') | ||
| for command in $commands | ||
| echo $command | ||
| end | ||
| end | ||
|
|
||
| # Add options | ||
| complete \ | ||
| --command dash-util \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_util_get_commands)" \ | ||
| --arguments "(__fish_dash_util_get_options)" | ||
|
|
||
| # Add commands | ||
| complete \ | ||
| --command dash-util \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_util_get_commands)" \ | ||
| --arguments "(__fish_dash_util_get_commands)" | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dash-wallet --no-files | ||
|
|
||
| # Extract options | ||
| function __fish_dash_wallet_get_options | ||
| set --local cmd (commandline -opc)[1] | ||
| for option in ($cmd -help 2>&1 | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=') | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
| # Extract commands | ||
| function __fish_dash_wallet_get_commands | ||
| set --local cmd (commandline -opc)[1] | ||
| for command in ($cmd -help | sed -e '1,/Commands:/d' -e 's/=/=\t/' -e 's/(=/=/' -e '/^ [a-z]/ p' -e d | string replace -r '\ \ ' '') | ||
| echo $command | ||
| end | ||
| end | ||
|
|
||
| # Add options | ||
| complete \ | ||
| --command dash-wallet \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_wallet_get_commands)" \ | ||
| --arguments "(__fish_dash_wallet_get_options)" | ||
|
|
||
| # Add commands | ||
| complete \ | ||
| --command dash-wallet \ | ||
| --condition "not __fish_seen_subcommand_from (__fish_dash_wallet_get_commands)" \ | ||
| --arguments "(__fish_dash_wallet_get_commands)" | ||
|
|
||
| # Add file completions for load and set commands | ||
| complete --command dash-wallet \ | ||
| --condition "string match -r -- '(dumpfile|datadir)*=' (commandline -pt)" \ | ||
| --force-files | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| # Disable files from being included in completions by default | ||
| complete --command dashd --no-files | ||
|
|
||
| # Extract options | ||
| function __fish_dashd_get_options | ||
| argparse 'nofiles' -- $argv | ||
| set --local cmd (commandline -opc)[1] | ||
| set --local options | ||
|
|
||
| if set -q _flag_nofiles | ||
| set --append options ($cmd -help-debug | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match --invert -r '^.*=$') | ||
| else | ||
| set --append options ($cmd -help-debug | string match -r '^ -.*' | string replace -r ' -' '-' | string replace -r '=.*' '=' | string match -r '^.*=$') | ||
| end | ||
|
|
||
| for option in $options | ||
| echo $option | ||
| end | ||
| end | ||
|
|
||
|
|
||
| # Add options with file completion | ||
| complete \ | ||
| --command dashd \ | ||
| --arguments "(__fish_dashd_get_options)" | ||
| # Enable file completions only if the commandline now contains a `*.=` style option | ||
| complete --command dashd \ | ||
| --condition 'string match --regex -- ".*=" (commandline -pt)' \ | ||
| --force-files | ||
|
|
||
| # Add options without file completion | ||
| complete \ | ||
| --command dashd \ | ||
| --arguments "(__fish_dashd_get_options --nofiles)" | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| Low-level changes | ||
| ================= | ||
|
|
||
| RPC | ||
| --- | ||
|
|
||
| - RPC `listsinceblock` now accepts an optional `label` argument | ||
| to fetch incoming transactions having the specified label. (#25934) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.