Skip to content

Commit e5afce2

Browse files
authored
Merge pull request #3 from RedisJSON/rename_jsonpath_calculator_to_jsonpath_rs
rename jsonpath_calculator -> jsonpath_rs
2 parents b0ece4c + 68d0449 commit e5afce2

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ serde_json = { version = "1.0", features = ["preserve_order"] }
1313
ijson = "0.1.3"
1414

1515
[lib]
16-
name = "jsonpath_calculator"
16+
name = "jsonpath_rs"
1717
path = "src/lib.rs"
1818
crate-type = ["cdylib", "rlib"]

README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,18 @@ Add the following to your cargo.toml
1111

1212
```rust
1313
[dependencies]
14-
jsonpath_calculator = { git = "https://github.com/RedisJSON/JsonPathCalculator.git", branch = "master" }
14+
jsonpath_rs = { git = "https://github.com/RedisJSON/JsonPathCalculator.git", branch = "master" }
1515
```
1616

1717
Usage example:
1818

1919
```rust
20-
extern crate jsonpath_calculator
20+
extern crate jsonpath_rs
2121
#[macro_use] extern crate serde_json;
2222

2323
fn main() {
24-
let mut query = jsonpath_calculator::compile("$..friends[0]");
25-
let calculator = jsonpath_calculator::create(&query)
24+
let mut query = jsonpath_rs::compile("$..friends[0]");
25+
let calculator = jsonpath_rs::create(&query)
2626

2727
let json_obj = json!({
2828
"school": {
@@ -47,7 +47,7 @@ fn main() {
4747
```
4848

4949
### Tests
50-
`jsonpath_calculator` pass **Almost** all the tests on https://github.com/freestrings/jsonpath, to run the tests:
50+
`jsonpath_rs` pass **Almost** all the tests on https://github.com/freestrings/jsonpath, to run the tests:
5151

5252
```rust
5353
cargo test

src/lib.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ use json_path::{
1616
/// Create a PathCalculator object. The path calculator can be re-used
1717
/// to calculate json paths on different jsons.
1818
/// /// ```rust
19-
/// extern crate jsonpath_calculator
19+
/// extern crate jsonpath_rs
2020
/// #[macro_use] extern crate serde_json;
2121
///
22-
/// let mut query = jsonpath_calculator::compile("$..friends[0]");
23-
/// let calculator = jsonpath_calculator::create(&query)
22+
/// let mut query = jsonpath_rs::compile("$..friends[0]");
23+
/// let calculator = jsonpath_rs::create(&query)
2424
///
2525
/// let json_obj = json!({
2626
/// "school": {

tests/common.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use std::io::Read;
22

33
use serde_json::Value;
44

5-
use jsonpath_calculator::{compile, create};
5+
use jsonpath_rs::{compile, create};
66

77
#[allow(dead_code)]
88
pub fn setup() {}

0 commit comments

Comments
 (0)