Skip to content
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

chore: update README #290

Merged
merged 2 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ tauri-build = "1.5.0"
Ensure you have [Tauri](https://beta.tauri.app/guides/create/) set up correctly. Then install the Rust instrumentation from crates.io:

```sh
cargo add tauri-plugin-devtools --git https://github.com/crabnebula-dev/devtools
cargo add tauri-plugin-devtools@2.0.0-beta
```

You also have to use Tauri **2.0.0-beta.1** (or later) so your `Cargo.toml` file should look as follows:
Expand Down
12 changes: 1 addition & 11 deletions crates/devtools-v1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,6 @@ Ensure you have [Tauri](https://tauri.app/v1/guides/getting-started/setup/) set
cargo add devtools
```

You also have to enable the `tracing` feature for Tauri, so your `Cargo.toml` file should look as follows:

```toml
[dependencies]
devtools = "0.2.4" # replace with latest
tauri = { version = "1.5.3", features = ["tracing"] }
[build-dependencies]
tauri-build = "1.5.0"
```

Then add the following snippet to your tauri initialization code:

```rust
Expand All @@ -37,7 +27,7 @@ fn main() {
let builder = builder.plugin(devtools);

builder
.run(tauri::generate_context!("./tauri.conf.json"))
.run(tauri::generate_context!())
.expect("error while running tauri application");
}
```
Expand Down
16 changes: 3 additions & 13 deletions crates/devtools/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,33 +11,23 @@ Inspect, monitor, and understand your [Tauri](https://tauri.app) application wit
Ensure you have [Tauri](https://tauri.app/v1/guides/getting-started/setup/) set up correctly. Then install the Rust instrumentation from crates.io:

```sh
cargo add devtools
```

You also have to enable the `tracing` feature for Tauri, so your `Cargo.toml` file should look as follows:

```toml
[dependencies]
devtools = "0.2.4" # replace with latest
tauri = { version = "1.5.3", features = ["tracing"] }
[build-dependencies]
tauri-build = "1.5.0"
cargo add tauri-plugin-devtools@2.0.0-beta
```

Then add the following snippet to your tauri initialization code:

```rust
fn main() {
#[cfg(debug_assertions)] // only enable instrumentation in development builds
let devtools = devtools::init();
let devtools = tauri_plugin_devtools::init();

let builder = tauri::Builder::default();

#[cfg(debug_assertions)]
let builder = builder.plugin(devtools);

builder
.run(tauri::generate_context!("./tauri.conf.json"))
.run(tauri::generate_context!())
.expect("error while running tauri application");
}
```
Expand Down