Skip to content

Commit

Permalink
Added error reports and logging
Browse files Browse the repository at this point in the history
  • Loading branch information
TheButlah committed Aug 29, 2023
1 parent 28884eb commit 9080796
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[env]
RUST_LOG="debug"
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 5 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[workspace]
resolver = "2"
members = [
"skills/cube"
"skills/cube",
]

# These settings will apply to all members of the workspace that opt in to them
Expand All @@ -13,7 +13,9 @@ edition = "2021"
rust-version = "1.72.0"

[workspace.dependencies]
eyre = "0.6"
color-eyre = "0.6"

bevy = "0.11"
color-eyre = "0.6"
eyre = "0.6"
tracing = "0.1"
tracing-subscriber = { verison = "0.3", features = ["env-filter", "tracing-log"] }
1 change: 1 addition & 0 deletions skills/cube/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ authors = ["Ryan Butler <thebutlah@gmail.com>"]
bevy.workspace = true
color-eyre.workspace = true
tracing.workspace = true
tracing-subscriber.workspace = true
5 changes: 4 additions & 1 deletion skills/cube/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@ use color_eyre::eyre::Result;
use tracing::info;

fn main() -> Result<()> {
// Set up nice error messages and logging
color_eyre::install()?;
info!("Hello world!");
tracing_subscriber::fmt::init();

info!("Running `cube` skill");

Ok(())
}

0 comments on commit 9080796

Please sign in to comment.