Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
hyf0 committed Apr 8, 2024
1 parent 3c997ce commit add7e84
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Sugar functions for manipulating paths.

## Main functionalities

- [SugarPath::as_path](https://docs.rs/sugar_path/latest/sugar_path/trait.SugarPath.html#tymethod.as_path) makes it easy to convert `T: Deref<Target = str>` to `Path` and allows to you methods of `SugarPath` on `&str` or `String` directly.
- [SugarPath::as_path](https://docs.rs/sugar_path/latest/sugar_path/trait.SugarPath.html#tymethod.as_path) makes it easy to convert `T: Deref<Target = str>` to `Path` and allows you to use methods of `SugarPath` on `&str` or `String` directly.

```rust
use std::path::Path;
Expand Down Expand Up @@ -66,7 +66,7 @@ use sugar_path::SugarPath;
}
#[cfg(target_family = "windows")]
{
assert_eq!(".\\world".absolutize_with("C:\\hello"), "C:\\hello\\world".as_path());
assert_eq!(".\\world".absolutize_with("C:\\hello"), "C:\\hello\\world".as_path());
assert_eq!("..\\world".absolutize_with("C:\\hello"), "C:\\world".as_path());
}
```
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
//! [![MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
//!
//! ## Main functionalities
//! - [SugarPath::as_path] makes it easy to convert `T: Deref<Target = str>` to [Path](std::path::Path) and allows to you methods of [SugarPath] on `&str` or `String` directly.
//! - [SugarPath::as_path] makes it easy to convert `T: Deref<Target = str>` to [Path](std::path::Path) and allows you to use methods of [SugarPath] on `&str` or `String` directly.
//!
//! ```rust
//! use std::path::Path;
Expand Down

0 comments on commit add7e84

Please sign in to comment.