diff --git a/VERSION b/VERSION new file mode 100644 index 0000000000..972ef76ad1 --- /dev/null +++ b/VERSION @@ -0,0 +1 @@ +0.7.9 diff --git a/src/blenderbim/Makefile b/src/blenderbim/Makefile index 4a9f3057fc..10d47852d0 100644 --- a/src/blenderbim/Makefile +++ b/src/blenderbim/Makefile @@ -35,7 +35,12 @@ SED:=sed -i '' -e endif endif -VERSION:=`date '+%y%m%d'` +IS_DEV_BUILD:=TRUE +VERSION:=`cat '../../VERSION'` +VERSION_MAJOR:=`cat '../../VERSION' | cut -d '.' -f 1` +VERSION_MINOR:=`cat '../../VERSION' | cut -d '.' -f 2` +VERSION_PATCH:=`cat '../../VERSION' | cut -d '.' -f 3` +VERSION_DATE:=`date '+%y%m%d'` LAST_COMMIT_HASH:=$(shell git rev-parse HEAD) PYVERSION:=py310 PYPI_IMP:=cp @@ -281,10 +286,16 @@ endif rm -rf dist/blenderbim/libs/site/packages/numpy rm -rf dist/blenderbim/libs/site/packages/numpy.libs - cd dist/blenderbim && $(SED) "s/999999/$(VERSION)/" __init__.py - cd dist/blenderbim && $(SED) "s/999999/$(VERSION)/" blender_manifest.toml +ifeq ($(IS_DEV_BUILD), TRUE) + cd dist/blenderbim && $(SED) "s/9, 9, 9/$(VERSION_MAJOR), $(VERSION_MINOR), $(VERSION_PATCH), $(VERSION_DATE)/" __init__.py + cd dist/blenderbim && $(SED) "s/9.9.9/$(VERSION).$(VERSION_DATE)/" blender_manifest.toml cd dist/blenderbim/bim && $(SED) "s/8888888/$(LAST_COMMIT_HASH)/" __init__.py + cd dist && zip -r blenderbim-$(VERSION).$(VERSION_DATE)-$(PYVERSION)-$(PLATFORM).zip ./* +else + cd dist/blenderbim && $(SED) "s/9, 9, 9/$(VERSION_MAJOR), $(VERSION_MINOR), $(VERSION_PATCH)/" __init__.py + cd dist/blenderbim && $(SED) "s/9.9.9/$(VERSION)/" blender_manifest.toml cd dist && zip -r blenderbim-$(VERSION)-$(PYVERSION)-$(PLATFORM).zip ./* +endif rm -rf dist/blenderbim .PHONY: test diff --git a/src/blenderbim/blenderbim/__init__.py b/src/blenderbim/blenderbim/__init__.py index ae13046dd7..db7ca7fdcc 100644 --- a/src/blenderbim/blenderbim/__init__.py +++ b/src/blenderbim/blenderbim/__init__.py @@ -29,7 +29,6 @@ if IN_BLENDER: import bpy import platform import traceback -import subprocess import webbrowser import addon_utils from collections import deque @@ -39,7 +38,7 @@ bl_info = { "description": "Transforms Blender into a native Building Information Model authoring platform using IFC.", "author": "IfcOpenShell Contributors", "blender": (3, 1, 0), - "version": (0, 0, 999999), + "version": (9, 9, 9), "location": "File Menu, Scene Properties Tab. See documentation for more.", "doc_url": "https://docs.blenderbim.org/", "tracker_url": "https://github.com/IfcOpenShell/IfcOpenShell/issues", diff --git a/src/blenderbim/blenderbim/blender_manifest.toml b/src/blenderbim/blenderbim/blender_manifest.toml index 1e39c56d7c..3f30484bf7 100644 --- a/src/blenderbim/blenderbim/blender_manifest.toml +++ b/src/blenderbim/blenderbim/blender_manifest.toml @@ -1,6 +1,6 @@ schema_version = "1.0.0" id = "blenderbim" -version = "0.0.999999" +version = "9.9.9" name = "BlenderBIM" tagline = "Transforms Blender into a native Building Information Model authoring platform using IFC." maintainer = "Dion Moult " diff --git a/src/blenderbim/docs/conf.py b/src/blenderbim/docs/conf.py index 5ce2385cac..a63280e398 100644 --- a/src/blenderbim/docs/conf.py +++ b/src/blenderbim/docs/conf.py @@ -28,7 +28,7 @@ # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. # -# import os +import os # import sys # sys.path.insert(0, os.path.abspath('.')) @@ -40,7 +40,9 @@ copyright = "2020-2024 IfcOpenShell Contributors" author = "IfcOpenShell Contributors" # The full version, including alpha/beta/rc tags -release = "0.0.240402" +cwd = os.path.dirname(os.path.realpath(__file__)) +with open(os.path.join(cwd, "..", "..", "..", "VERSION"), "r") as f: + release = f.read().strip() # -- General configuration --------------------------------------------------- diff --git a/src/ifcopenshell-python/docs/conf.py b/src/ifcopenshell-python/docs/conf.py index 9106e4359e..083292ff96 100644 --- a/src/ifcopenshell-python/docs/conf.py +++ b/src/ifcopenshell-python/docs/conf.py @@ -36,11 +36,13 @@ sys.path.insert(0, os.path.abspath('..')) # -- Project information ----------------------------------------------------- project = "IfcOpenShell" -copyright = "2011-2024, IfcOpenShell Contributors" +copyright = "2011-2024 IfcOpenShell Contributors" author = "IfcOpenShell Contributors" # The full version, including alpha/beta/rc tags -release = "0.7.0" +cwd = os.path.dirname(os.path.realpath(__file__)) +with open(os.path.join(cwd, "..", "..", "..", "VERSION"), "r") as f: + release = f.read().strip() # -- General configuration ---------------------------------------------------