Initial scaffold: Rust server workspace (sb-api, sb-core, sb-db, sb-auth, sb-shared) + sb-common dependency + systemd

This commit is contained in:
Jan-Peter von Hunnius 2026-08-02 12:48:08 +02:00
commit 7a75a523f0
39 changed files with 183 additions and 0 deletions

13
crates/sb-core/Cargo.toml Normal file
View file

@ -0,0 +1,13 @@
[package]
name = "sb-core"
version = "0.1.0"
edition = "2024"
[dependencies]
serde = { version = "1", features = ["derive"] }
serde_json = "1"
rand = "0.9"
chrono = { version = "0.4", features = ["serde"] }
thiserror = "2"
sb-shared = { path = "../sb-shared" }
sb-common = { path = "/home/jan/Development/skara-brae/skara-brae-common/rust" }

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1,13 @@
pub mod mod;
use sb_common::PROJECT_NAME;
const WEAPONS: &str = include_str!("../../../../skara-brae-common/data/items/weapons.json");
pub fn game_name() -> &'static str {
PROJECT_NAME
}
pub fn load_weapons() -> Vec<serde_json::Value> {
serde_json::from_str(WEAPONS).expect("failed to parse weapons data")
}

14
crates/sb-core/src/lib.rs Normal file
View file

@ -0,0 +1,14 @@
#![allow(dead_code)]
pub mod character;
pub mod combat;
pub mod adventure;
pub mod economy;
pub mod guild;
pub mod crafting;
pub mod pets;
pub mod blessings;
pub mod workers;
pub mod slayer;
pub mod world;
pub mod rules;

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@