Skip to main content

kobe_btc/
lib.rs

1//! Bitcoin wallet utilities for Kobe CLI.
2//!
3//! Provides Bitcoin address derivation from a unified [`kobe::Wallet`].
4//!
5//! # Features
6//!
7//! - `std` (default): Enable standard library support
8//! - `alloc`: Enable heap allocation without full std (for `no_std` environments)
9//! - `rand`: Enable random key generation for `StandardWallet`
10
11#![cfg_attr(not(feature = "std"), no_std)]
12
13#[cfg(feature = "alloc")]
14extern crate alloc;
15
16#[cfg(feature = "alloc")]
17mod address;
18#[cfg(feature = "alloc")]
19mod deriver;
20mod error;
21mod network;
22#[cfg(feature = "alloc")]
23mod standard_wallet;
24mod types;
25
26#[cfg(feature = "alloc")]
27pub use deriver::{DerivedAddress, Deriver};
28pub use error::Error;
29pub use network::{Network, ParseNetworkError};
30#[cfg(feature = "alloc")]
31pub use standard_wallet::StandardWallet;
32#[cfg(feature = "alloc")]
33pub use types::DerivationPath;
34pub use types::{AddressType, ParseAddressTypeError};
35
36/// A convenient Result type alias for kobe-btc operations.
37pub type Result<T> = core::result::Result<T, Error>;