mirror of
https://github.com/chatmail/core.git
synced 2026-05-04 13:56:30 +03:00
feat: load package version during build
This removes the duplication of the version string between the `Cargo.toml` and `constants.rs`
This commit is contained in:
committed by
holger krekel
parent
7d51c6e4f4
commit
99aabef7f3
@@ -1,8 +1,13 @@
|
||||
//! Constants
|
||||
#![allow(non_camel_case_types)]
|
||||
|
||||
use lazy_static::lazy_static;
|
||||
|
||||
use deltachat_derive::*;
|
||||
|
||||
pub const DC_VERSION_STR: &[u8; 14] = b"1.0.0-alpha.3\x00";
|
||||
lazy_static! {
|
||||
pub static ref DC_VERSION_STR: String = env!("CARGO_PKG_VERSION").to_string();
|
||||
}
|
||||
|
||||
#[repr(u8)]
|
||||
#[derive(Debug, Display, Clone, Copy, PartialEq, Eq, FromPrimitive, ToPrimitive, ToSql, FromSql)]
|
||||
|
||||
Reference in New Issue
Block a user