From 2aabe2eb9d0cbd147ec44fee6f45661ffa28746b Mon Sep 17 00:00:00 2001 From: Mohamed Awnallah Date: Thu, 21 Mar 2024 04:20:24 +0200 Subject: [PATCH] lncli: add include_raw_tx flag to bumpfee command --- cmd/commands/walletrpc_active.go | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/cmd/commands/walletrpc_active.go b/cmd/commands/walletrpc_active.go index b098c40b0c..e531590e98 100644 --- a/cmd/commands/walletrpc_active.go +++ b/cmd/commands/walletrpc_active.go @@ -307,6 +307,16 @@ var bumpFeeCommand = cli.Command{ the budget for fee bumping; for existing inputs, their current budgets will be retained.`, }, + cli.BoolFlag{ + Name: "include_raw_tx", + Usage: "include the raw transaction hex for the " + + "sweep transaction on success. " + + "It waits for the batcher to create a " + + "transaction, which might take a while. " + + "The duration is at least as long as " + + "the configured sweeper.batchwindowduration, " + + "with the default set to 30 seconds", + }, }, Action: actionDecorator(bumpFee), } @@ -344,11 +354,12 @@ func bumpFee(ctx *cli.Context) error { } resp, err := client.BumpFee(ctxc, &walletrpc.BumpFeeRequest{ - Outpoint: protoOutPoint, - TargetConf: uint32(ctx.Uint64("conf_target")), - Immediate: immediate, - Budget: ctx.Uint64("budget"), - SatPerVbyte: ctx.Uint64("sat_per_vbyte"), + Outpoint: protoOutPoint, + TargetConf: uint32(ctx.Uint64("conf_target")), + Immediate: immediate, + Budget: ctx.Uint64("budget"), + SatPerVbyte: ctx.Uint64("sat_per_vbyte"), + IncludeRawTx: ctx.Bool("include_raw_tx"), }) if err != nil { return err