mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-11 10:06:47 +00:00
Get package version from pyproject.toml
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
# along with ifccityjson. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import os
|
||||
from importlib.metadata import version as pkg_version
|
||||
import ifcopenshell
|
||||
import ifcopenshell.api
|
||||
from datetime import datetime
|
||||
@@ -196,7 +197,7 @@ class Cityjson2ifc:
|
||||
"IfcOpenShell, an open source (LGPL) software library that helps users and software developers to work with the IFC file format.",
|
||||
)
|
||||
p_o = self.IFC_model.createIfcPersonAndOrganization(person, organization)
|
||||
application = self.IFC_model.createIfcApplication(organization, "v0.0.x", "ifccityjson", "ifccityjson")
|
||||
application = self.IFC_model.createIfcApplication(organization, pkg_version("ifccityjson"), "ifccityjson", "ifccityjson")
|
||||
timestamp = int(datetime.now().timestamp())
|
||||
ownerHistory = self.IFC_model.createIfcOwnerHistory(p_o, application, "READWRITE", None, None, None, None,
|
||||
timestamp)
|
||||
|
||||
Reference in New Issue
Block a user