mirror of
https://github.com/Lumither/nocturne.git
synced 2026-10-17 10:26:21 +00:00
feat(backend, lb) add missing components
This commit is contained in:
4 files changed
+39
No files matched your search
@@ -0,0 +1,15 @@
|
||||
[package]
|
||||
name = "server"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
macros = { path = "../macros" }
|
||||
|
||||
|
||||
tracing = "0.1.41"
|
||||
git2 = "0.20.0"
|
||||
|
||||
[build-dependencies]
|
||||
git2 = "0.20.0"
|
||||
chrono = "0.4.39"
|
||||
@@ -0,0 +1,15 @@
|
||||
use chrono::Utc;
|
||||
use git2::Repository;
|
||||
|
||||
fn main() {
|
||||
let repo = Repository::open("../..").expect("failed to open repository");
|
||||
let commit = repo
|
||||
.head()
|
||||
.expect("failed to get HEAD")
|
||||
.peel_to_commit()
|
||||
.expect("failed to get HEAD commit");
|
||||
let hash = commit.id().to_string();
|
||||
let utc_date = Utc::now().date_naive().format("%Y%m%d").to_string();
|
||||
let build_id = format!("{}@{}", utc_date, &hash[..8]);
|
||||
println!("cargo:rustc-env=BUILD_ID={}", build_id);
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
[package]
|
||||
name = "loadbalancer"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
@@ -0,0 +1,3 @@
|
||||
fn main() {
|
||||
println!("Hello, world!");
|
||||
}
|
||||
Reference in new issue
Block a user