Boilerplate for core library and CLI binary.

This commit is contained in:
alexiondev
2026-04-27 23:45:02 +00:00
parent 4f4035b391
commit 5bd5839ecf
10 changed files with 78 additions and 0 deletions

7
core/Cargo.lock generated Normal file
View File

@@ -0,0 +1,7 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
version = 4
[[package]]
name = "core"
version = "0.1.0"

6
core/Cargo.toml Normal file
View File

@@ -0,0 +1,6 @@
[package]
name = "core"
version = "0.1.0"
edition = "2024"
[dependencies]

14
core/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);
}
}