Skip to content

Commit a33eff4

Browse files
committed
lsp_plugin: add lsps2 models
Add models and options to enable lsps2 on the lsp Signed-off-by: Peter Neuroth <pet.v.ne@gmail.com>
1 parent fed5a3a commit a33eff4

File tree

7 files changed

+718
-10
lines changed

7 files changed

+718
-10
lines changed

Cargo.lock

Lines changed: 9 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

plugins/lsps-plugin/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ path = "src/service.rs"
1414
[dependencies]
1515
anyhow = "1.0"
1616
async-trait = "0.1"
17-
chrono = "0.4.42"
17+
bitcoin = "0.31"
18+
chrono = { version= "0.4.42", features = ["serde"] }
1819
cln-plugin = { version = "0.5", path = "../" }
1920
cln-rpc = { version = "0.5", path = "../../cln-rpc" }
2021
hex = "0.4"

plugins/lsps-plugin/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
pub mod jsonrpc;
22
pub mod lsps0;
3+
pub mod lsps2;
34
pub mod util;
45

56
pub const LSP_FEATURE_BIT: usize = 729;
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
use cln_plugin::options;
2+
3+
pub mod model;
4+
5+
pub const OPTION_ENABLED: options::FlagConfigOption = options::ConfigOption::new_flag(
6+
"dev-lsps2-service-enabled",
7+
"Enables lsps2 for the LSP service",
8+
);
9+
10+
pub const OPTION_PROMISE_SECRET: options::StringConfigOption =
11+
options::ConfigOption::new_str_no_default(
12+
"dev-lsps2-promise-secret",
13+
"A 64-character hex string that is the secret for promises",
14+
);

0 commit comments

Comments
 (0)