This commit is contained in:
Crispy 2024-04-29 21:40:22 +02:00
commit b62f3a016d
8 changed files with 4045 additions and 0 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
/target

3997
Cargo.lock generated Normal file

File diff suppressed because it is too large Load diff

11
Cargo.toml Normal file
View file

@ -0,0 +1,11 @@
[workspace]
resolver = "2"
members = ["petri", "uscope"]
# Enable a small amount of optimization in debug mode
[profile.dev]
opt-level = 1
# Enable high optimizations for dependencies (incl. Bevy), but not for our code:
[profile.dev.package."*"]
opt-level = 3

8
petri/Cargo.toml Normal file
View file

@ -0,0 +1,8 @@
[package]
name = "petri"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]

14
petri/src/lib.rs Normal file
View file

@ -0,0 +1,14 @@
pub fn add(left: usize, right: usize) -> usize {
left + right
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn it_works() {
let result = add(2, 2);
assert_eq!(result, 4);
}
}

1
rustfmt.toml Normal file
View file

@ -0,0 +1 @@
hard_tabs = true

10
uscope/Cargo.toml Normal file
View file

@ -0,0 +1,10 @@
[package]
name = "uscope"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
petri = { path = "../petri" }
bevy = { version = "0.13", features = ["dynamic_linking"] }

3
uscope/src/main.rs Normal file
View file

@ -0,0 +1,3 @@
fn main() {
println!("Hello, world!");
}