-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplifies the cln plugin option parsing
Options include helper functions to convert them to their proper type after `cln-plugin=0.1.2`. Use that to reduce the option parsing boilerplate.
- Loading branch information
Showing
3 changed files
with
42 additions
and
34 deletions.
There are no files selected for viewing
This file contains 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 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 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 @@ | ||
/// Collections of plugin option names and default values | ||
pub const WT_PORT: &str = "watchtower-port"; | ||
pub const DEFAULT_WT_PORT: i64 = 9814; | ||
pub const WT_MAX_RETRY_TIME: &str = "watchtower-max-retry-time"; | ||
pub const DEFAULT_WT_MAX_RETRY_TIME: i64 = 900; | ||
pub const DEV_WT_MAX_RETRY_INTERVAL: &str = "dev-watchtower-max-retry-interval"; | ||
pub const DEFAULT_DEV_WT_MAX_RETRY_INTERVAL: i64 = 60; |