-
Notifications
You must be signed in to change notification settings - Fork 404
Remove examples folder, add rustdoc examples #2006
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Remove examples folder, add rustdoc examples #2006
Conversation
Thanks for working on this one. |
bcf49f0
to
7448a99
Compare
@oleonardolima thank you. CI "should" be fixed now, at least it is locally. Can we try again? |
0e68ca5
to
9a9f9af
Compare
Thanks, there are some unrelated already merged commits, you probably need to do a rebase on top of master. Also, please note that we follow the conventional commits for commit messages, which would also need an update. |
Removed /examples folder containing CLI-heavy examples Added focused rustdoc examples to key functions: - IndexedTxGraph::new() - graph initialization - BdkElectrumClient::new() - client creation - BdkElectrumClient::sync() - blockchain sync - BdkElectrumClient::full_scan() - wallet restoration - TxGraph::insert_tx() - transaction insertion - TxGraph::balance() - balance calculation - TxGraph::filter_chain_unspents() - UTXO retrieval - KeychainTxOutIndex::reveal_next_spk() - address generation - KeychainTxOutIndex::insert_descriptor() - descriptor setup - IndexedTxGraph::apply_block_relevant() - block processing - EsploraExt::full_scan() - Esplora wallet scanning Updated Cargo.toml workspace members Rationale: The previous examples contained 300+ lines of CLI boilerplate that obscured the core BDK functionality. The new rustdoc examples are 10-15 lines each and focus purely on API usage, making them much easier for developers to understand and follow. The maintained bdk-cli tool serves as the comprehensive CLI example.
9a9f9af
to
dc4e009
Compare
@oleonardolima ok should be ready to test CI now. Thanks! |
64b327d
to
1f81e2c
Compare
1f81e2c
to
fa85989
Compare
Closes #1973
Changes
/examples
folder containing CLI-heavy examplesIndexedTxGraph::new()
- graph initializationBdkElectrumClient::new()
- client creationBdkElectrumClient::sync()
- blockchain syncBdkElectrumClient::full_scan()
- wallet restorationTxGraph::insert_tx()
- transaction insertionTxGraph::balance()
- balance calculationTxGraph::filter_chain_unspents()
- UTXO retrievalKeychainTxOutIndex::reveal_next_spk()
- address generationKeychainTxOutIndex::insert_descriptor()
- descriptor setupIndexedTxGraph::apply_block_relevant()
- block processingEsploraExt::full_scan()
- Esplora wallet scanningCargo.toml
workspace membersRationale
The previous examples contained 300+ lines of CLI boilerplate that obscured the core BDK functionality. The new rustdoc examples are 10-15 lines each and focus purely on API usage, making them much easier for developers to understand and follow.
The maintained
bdk-cli
tool serves as the comprehensive CLI example.