mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-18 22:33:33 +00:00
add build to Makefile and use it in bcf-pypi Workflow
This commit is contained in:
committed by
Thomas Krijnen
parent
61a7325bc0
commit
b8168ca606
@@ -48,10 +48,10 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
pip install build
|
pip install build
|
||||||
cd src/bcf &&
|
cd src/bcf &&
|
||||||
python -m build
|
make dist
|
||||||
- name: Publish a Python distribution to PyPI
|
- name: Publish a Python distribution to PyPI
|
||||||
uses: ortega2247/pypi-upload-action@master
|
uses: ortega2247/pypi-upload-action@master
|
||||||
with:
|
with:
|
||||||
user: __token__
|
user: __token__
|
||||||
password: ${{ secrets.PYPI_API_TOKEN }}
|
password: ${{ secrets.PYPI_API_TOKEN }}
|
||||||
packages_dir: src/bcf/dist
|
packages_dir: src/bcf/dist
|
||||||
+14
-1
@@ -1,3 +1,9 @@
|
|||||||
|
VERSION:=`date '+%y%m%d'`
|
||||||
|
SED:=sed -i
|
||||||
|
ifeq ($(UNAME_S),Darwin)
|
||||||
|
SED:=sed -i '' -e
|
||||||
|
endif
|
||||||
|
|
||||||
.PHONY: ci
|
.PHONY: ci
|
||||||
ci:
|
ci:
|
||||||
tox
|
tox
|
||||||
@@ -12,6 +18,13 @@ models:
|
|||||||
cd src && xsdata generate -p bcf.v2.model --unnest-classes --kw-only --slots -ds Google bcf/v2/xsd
|
cd src && xsdata generate -p bcf.v2.model --unnest-classes --kw-only --slots -ds Google bcf/v2/xsd
|
||||||
cd src && xsdata generate -p bcf.v3.model --unnest-classes --kw-only --slots -ds Google bcf/v3/xsd
|
cd src && xsdata generate -p bcf.v3.model --unnest-classes --kw-only --slots -ds Google bcf/v3/xsd
|
||||||
|
|
||||||
|
.PHONY: dist
|
||||||
|
dist:
|
||||||
|
rm -rf dist
|
||||||
|
$(SED) "s/999999/$(VERSION)/" pyproject.toml
|
||||||
|
python -m build
|
||||||
|
$(SED) "s/$(VERSION)/999999/" pyproject.toml
|
||||||
|
|
||||||
# .PHONY
|
# .PHONY
|
||||||
# api:
|
# api:
|
||||||
# openapi-python-client generate --url https://api.swaggerhub.com/apis/buildingSMART/BCF/3.0
|
# openapi-python-client generate --url https://api.swaggerhub.com/apis/buildingSMART/BCF/3.0
|
||||||
@@ -17,7 +17,7 @@ dependencies = [
|
|||||||
"numpy",
|
"numpy",
|
||||||
"ifcopenshell",
|
"ifcopenshell",
|
||||||
]
|
]
|
||||||
version = "0.0.1"
|
version = "0.0.999999"
|
||||||
classifiers = [
|
classifiers = [
|
||||||
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
||||||
"Operating System :: OS Independent",
|
"Operating System :: OS Independent",
|
||||||
@@ -76,7 +76,7 @@ deps =
|
|||||||
black
|
black
|
||||||
isort
|
isort
|
||||||
pylint
|
pylint
|
||||||
commands =
|
commands =
|
||||||
black {posargs:.}
|
black {posargs:.}
|
||||||
isort {posargs:.}
|
isort {posargs:.}
|
||||||
pylint {posargs:.} --output-format=colorized
|
pylint {posargs:.} --output-format=colorized
|
||||||
@@ -138,4 +138,4 @@ max-attributes = 10
|
|||||||
|
|
||||||
[tool.pylint.format]
|
[tool.pylint.format]
|
||||||
expected-line-ending-format = "LF"
|
expected-line-ending-format = "LF"
|
||||||
max-line-length = 120
|
max-line-length = 120
|
||||||
Reference in New Issue
Block a user