Added no-assets feature to common

This commit is contained in:
Joshua Barretto 2020-01-27 22:41:30 +00:00
parent 56a553c968
commit e391d6e4fd
3 changed files with 5 additions and 2 deletions

View File

@ -5,7 +5,7 @@ authors = ["Joshua Barretto <joshua.s.barretto@gmail.com>"]
edition = "2018"
[dependencies]
common = { package = "veloren-common", path = "../common" }
common = { package = "veloren-common", path = "../common", features = ["no-assets"] }
byteorder = "1.3.2"
uvth = "3.1.1"

View File

@ -4,6 +4,9 @@ version = "0.4.0"
authors = ["Joshua Barretto <joshua.s.barretto@gmail.com>", "Maciej Ćwięka <mckol363@gmail.com>", "Imbris <imbrisf@gmail.com>"]
edition = "2018"
[features]
no-assets = []
[dependencies]
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git" }

View File

@ -36,7 +36,7 @@ fn main() {
Err(e) => panic!("failed to retrieve current git commit hash: {}", e),
}
// Check if git-lfs is working
if std::env::var("DISABLE_GIT_LFS_CHECK").is_err() {
if std::env::var("DISABLE_GIT_LFS_CHECK").is_err() || cfg!(not(feature = "no-assets")) {
let asset_path: PathBuf = ["..", "assets", "voxygen", "background", "bg_main.png"]
.iter()
.collect();