Include git commit in conan version
continuous-integration/drone/push Build is failing Details

This commit is contained in:
Deukhoofd 2019-12-19 15:48:35 +01:00
parent f975722cd4
commit 9b198e67a7
Signed by: Deukhoofd
GPG Key ID: ADF2E9256009EDCE
1 changed files with 5 additions and 2 deletions

View File

@ -1,9 +1,8 @@
from conans import ConanFile, CMake
from conans import ConanFile, CMake, tools
class HelloConan(ConanFile):
name = "CreatureLib"
version = "0.1"
license = "TODO"
url = "https://git.p-epsilon.com/Deukhoofd/CreatureLib"
description = "The core implementation for turn based battling using creatures."
@ -13,6 +12,10 @@ class HelloConan(ConanFile):
generators = "cmake"
exports_sources = "*"
def set_version(self):
git = tools.Git(folder=self.recipe_folder)
self.version = "%s_%s" % (git.get_branch(), git.get_revision())
def build(self):
cmake = CMake(self)
cmake.configure(source_folder=".")