Skip to content

Commit f1d737c

Browse files
multi: add accounts u --new_balance deprecation
This commit adds a deprecation notice regarding the `accounts update --new_balance` flag. This flag will be removed in the next major release of lit.
1 parent 5b6edb4 commit f1d737c

File tree

6 files changed

+112
-94
lines changed

6 files changed

+112
-94
lines changed

cmd/litcli/accounts.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,10 @@ var updateAccountCommand = cli.Command{
160160
},
161161
cli.Int64Flag{
162162
Name: "new_balance",
163-
Usage: "The new balance of the account; -1 means do " +
164-
"not update the balance.",
165-
Value: -1,
163+
Usage: "(deprecated) The new balance of the account; " +
164+
"-1 means do not update the balance.",
165+
Value: -1,
166+
Hidden: true,
166167
},
167168
cli.Int64Flag{
168169
Name: "new_expiration_date",

docs/release-notes/release-notes-0.14.2.md

+7
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@
3232
allow increasing or decreasing the balance of an off-chain account by a
3333
specified amount.
3434

35+
36+
* The [`accounts update` `--new_balance` flag has been
37+
deprecated](https://github.com/lightninglabs/lightning-terminal/pull/974).
38+
Use the `accounts credit` and `accounts debit` commands instead, to update
39+
an account's balance. The flag will no longer be supported in Lightning
40+
Terminal `v0.16.0-alpha`.
41+
3542
## Integrated Binary Updates
3643

3744
### LND

litrpc/lit-accounts.pb.go

+90-86
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

litrpc/lit-accounts.proto

+5-2
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,11 @@ message UpdateAccountRequest {
144144
// The ID of the account to update. Either the ID or the label must be set.
145145
string id = 1;
146146

147-
// The new account balance to set. Set to -1 to not update the balance.
148-
int64 account_balance = 2;
147+
/*
148+
Deprecated, use credit or debit command instead. The new account balance to
149+
set. Set to -1 to not update the balance.
150+
*/
151+
int64 account_balance = 2 [deprecated = true];
149152

150153
/*
151154
The new account expiry to set. Set to -1 to not update the expiry. Set to 0

litrpc/lit-accounts.swagger.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@
278278
"account_balance": {
279279
"type": "string",
280280
"format": "int64",
281-
"description": "The new account balance to set. Set to -1 to not update the balance."
281+
"description": "Deprecated, use credit or debit command instead. The new account balance to\nset. Set to -1 to not update the balance."
282282
},
283283
"expiration_date": {
284284
"type": "string",

0 commit comments

Comments
 (0)