IfcPatch workflow now uses VERSION

This commit is contained in:
Dion Moult
2024-06-12 18:05:33 +10:00
parent 45b81ab814
commit 85e1786ce5
4 changed files with 11 additions and 17 deletions
+7 -3
View File
@@ -16,7 +16,7 @@
# You should have received a copy of the GNU Lesser General Public License
# along with IfcPatch. If not, see <http://www.gnu.org/licenses/>.
VERSION:=`date '+%y%m%d'`
VERSION:=$(shell cat ../../VERSION)
SED:=sed -i
ifeq ($(UNAME_S),Darwin)
SED:=sed -i '' -e
@@ -33,6 +33,10 @@ qa:
.PHONY: dist
dist:
rm -rf dist
$(SED) "s/999999/$(VERSION)/" pyproject.toml
cp pyproject.toml pyproject.toml.bak
cp ifcpatch/__init__.py __init__.py.bak
$(SED) 's/version = "0.0.0"/version = "$(VERSION)"/' pyproject.toml
$(SED) 's/version = "0.0.0"/version = "$(VERSION)"/' ifcpatch/__init__.py
python -m build
$(SED) "s/$(VERSION)/999999/" pyproject.toml
mv pyproject.toml.bak pyproject.toml
mv __init__.py.bak ifcpatch/__init__.py
+3
View File
@@ -29,6 +29,9 @@ import importlib
from typing import Union
__version__ = version = "0.0.0"
def execute(args: dict) -> Union[ifcopenshell.file, str]:
"""Execute a patch recipe
+1 -1
View File
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
[project]
name = "ifcpatch"
version = "0.0.999999"
version = "0.0.0"
authors = [
{ name="Dion Moult", email="dion@thinkmoult.com" },
]