From f57dc8e890869867879cd98896da859a1fdad10f Mon Sep 17 00:00:00 2001 From: Valentin Brandl Date: Mon, 29 Mar 2021 12:38:29 +0200 Subject: [PATCH] Fix vergen --- build.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/build.rs b/build.rs index 831db6b..75d940e 100644 --- a/build.rs +++ b/build.rs @@ -2,11 +2,12 @@ extern crate ructe; extern crate vergen; use ructe::Ructe; -use vergen::{gen, ConstantsFlags}; +use vergen::{vergen, Config, ShaKind}; fn main() { - let flags = ConstantsFlags::SHA_SHORT; - gen(flags).expect("Unable to generate the cargo keys!"); + let mut config = Config::default(); + *config.git_mut().sha_kind_mut() = ShaKind::Short; + vergen(config).expect("Unable to generate static repo info"); Ructe::from_env() .expect("ructe") .compile_templates("templates")