Changed build to static file so that build scripts can change it dynamically

This commit is contained in:
Shay Nehmad 2020-02-09 11:51:00 +02:00
parent fcef4f154f
commit 46952ed0ae
4 changed files with 11 additions and 3 deletions

1
monkey/common/BUILD Normal file
View File

@ -0,0 +1 @@
dev

View File

@ -1,10 +1,13 @@
# To get the version from shell, run `python ./version.py` (see `python ./version.py -h` for details).
import argparse
from pathlib import Path
MAJOR = "1"
MINOR = "8"
PATCH = "0"
BUILD = "dev"
build_file_path = Path(__file__).parent.joinpath("BUILD")
with open(build_file_path, "r") as build_file:
BUILD = build_file.read()
def get_version(build=BUILD):

View File

@ -19,7 +19,9 @@ def main():
hookspath=['./pyinstaller_hooks'],
runtime_hooks=None,
binaries=None,
datas=None,
datas=[
("../common/BUILD", "../common/BUILD")
],
excludes=None,
win_no_prefer_redirects=None,
win_private_assemblies=None,

View File

@ -15,7 +15,9 @@ def main():
hookspath=None,
runtime_hooks=None,
binaries=None,
datas=None,
datas=[
("../common/BUILD", "../common/BUILD")
],
excludes=None,
win_no_prefer_redirects=None,
win_private_assemblies=None,