Skip to content

Commit 6a70554

Browse files
authored
Merge pull request #1 from mayoreee/chore/update_names
chore: replace bitcoin with dashcore
2 parents 69ac802 + 4df2751 commit 6a70554

File tree

14 files changed

+254
-254
lines changed

14 files changed

+254
-254
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ use dashcore_rpc::{Auth, Client, RpcApi};
2626

2727
fn main() {
2828

29-
let rpc = Client::new("http://localhost:8332".to_string(),
29+
let rpc = Client::new(&"http://127.0.0.1:19998".to_string(),
3030
Auth::UserPass("<FILL RPC USERNAME>".to_string(),
3131
"<FILL RPC PASSWORD>".to_string())).unwrap();
3232
let best_block_hash = rpc.get_best_block_hash().unwrap();

client/Cargo.toml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
[package]
2-
name = "bitcoincore-rpc"
2+
name = "dashcore-rpc"
33
version = "0.15.0"
44
authors = [
55
"Steven Roose <[email protected]>",
66
"Jean Pierre Dudey <[email protected]>",
77
"Dawid Ciężarkiewicz <[email protected]>",
88
]
99
license = "CC0-1.0"
10-
homepage = "https://github.com/rust-bitcoin/rust-bitcoincore-rpc/"
11-
repository = "https://github.com/rust-bitcoin/rust-bitcoincore-rpc/"
12-
description = "RPC client library for the Bitcoin Core JSON-RPC API."
13-
keywords = ["crypto", "bitcoin", "bitcoin-core", "rpc"]
10+
homepage = "https://github.com/dashevo/rust-dashcore/"
11+
repository = "https://github.com/dashevo/rust-dashcore/"
12+
description = "RPC client library for the Dash Core JSON-RPC API."
13+
keywords = ["crypto", "dash", "dash-core", "rpc"]
1414
readme = "README.md"
1515

1616
[lib]
17-
name = "bitcoincore_rpc"
17+
name = "dashcore_rpc"
1818
path = "src/lib.rs"
1919

2020
[dependencies]
21-
bitcoincore-rpc-json = { version = "0.15.0", path = "../json" }
21+
dashcore-rpc-json = { version = "0.15.0", path = "../json" }
2222

2323
log = "0.4.5"
2424
jsonrpc = "0.12.0"

client/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
bitcoincore-rpc
1+
dashcore-rpc
22
===============
33

4-
Rust client library for the Bitcoin Core daemon's JSON-RPC API.
4+
Rust client library for the Dash Core daemon's JSON-RPC API.
55

6-
Separate `bitcoincore-rpc-json` crate with the JSON-enabled data types used
6+
Separate `dashcore-rpc-json` crate with the JSON-enabled data types used
77
in the interface of this crate.
88

99

client/examples/retry_client.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
// If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
99
//
1010

11-
extern crate bitcoincore_rpc;
11+
extern crate dashcore_rpc;
1212
extern crate jsonrpc;
1313
extern crate serde;
1414
extern crate serde_json;
1515

16-
use bitcoincore_rpc::{Client, Error, Result, RpcApi};
16+
use dashcore_rpc::{Client, Error, Result, RpcApi};
1717

1818
pub struct RetryClient {
1919
client: Client,

client/examples/test_against_node.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010

1111
//! A very simple example used as a self-test of this library against a Bitcoin
1212
//! Core node.
13-
extern crate bitcoincore_rpc;
13+
extern crate dashcore_rpc;
1414

15-
use bitcoincore_rpc::{bitcoin, Auth, Client, Error, RpcApi};
15+
use dashcore_rpc::{dashcore, Auth, Client, Error, RpcApi};
1616

1717
fn main_result() -> Result<(), Error> {
1818
let mut args = std::env::args();
@@ -35,10 +35,10 @@ fn main_result() -> Result<(), Error> {
3535
println!("best block hash by height: {}", best_block_hash_by_height);
3636
assert_eq!(best_block_hash_by_height, best_block_hash);
3737

38-
let bitcoin_block: bitcoin::Block = rpc.get_by_id(&best_block_hash)?;
39-
println!("best block hash by `get`: {}", bitcoin_block.header.prev_blockhash);
40-
let bitcoin_tx: bitcoin::Transaction = rpc.get_by_id(&bitcoin_block.txdata[0].txid())?;
41-
println!("tx by `get`: {}", bitcoin_tx.txid());
38+
let dashcore_block: dashcore::Block = rpc.get_by_id(&best_block_hash)?;
39+
println!("best block hash by `get`: {}", dashcore_block.header.prev_blockhash);
40+
let dashcore_tx: dashcore::Transaction = rpc.get_by_id(&dashcore_block.txdata[0].txid())?;
41+
println!("tx by `get`: {}", dashcore_tx.txid());
4242

4343
Ok(())
4444
}

0 commit comments

Comments
 (0)