Skip to content

Commit ab8596c

Browse files
committed
Merge branch 'master' of github.com:Loop3D/LoopStructural
2 parents f839500 + cb7be82 commit ab8596c

4 files changed

Lines changed: 60 additions & 79 deletions

File tree

.github/workflows/conda.yml

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,46 @@ name: publish_conda
33
on:
44
release:
55
types: [created, edited]
6+
67
jobs:
78
publish:
89
runs-on: ubuntu-latest
910
steps:
1011
- uses: actions/checkout@v2
1112
- name: Publish Loop Conda
12-
uses: Loop3D/conda-publish-action@1.8
13+
uses: Loop3D/conda-publish-action@1.9
1314
with:
1415
subdir: "conda"
1516
anacondatoken: ${{ secrets.CONDA }}
16-
platforms: "win osx linux"
17+
platforms: "linux"
18+
windows:
19+
runs-on: windows-2016
20+
strategy:
21+
matrix:
22+
python: ['3.6']
23+
steps:
24+
- uses: actions/checkout@v2
25+
- name: submodules
26+
shell: bash -l {0}
27+
run: |
28+
git submodule update --init --recursive
29+
- name: Add msbuild to PATH
30+
uses: microsoft/setup-msbuild@v1.0.2
31+
- uses: conda-incubator/setup-miniconda@v2
32+
with:
33+
python-version: ${{ matrix.python }}
34+
activate-environment: loop
35+
- name: Conda build
36+
shell: powershell
37+
run: |
38+
python --version
39+
conda install -c conda-forge conda-build scikit-build numpy cython
40+
cd conda
41+
conda build -c anaconda -c conda-forge -c loop3d -c conda-forge/label/cf202003 -c pytorch -c fcakyon -c districtdatalabs --output-folder . .
42+
- name: upload
43+
shell: powershell
44+
env:
45+
ANACONDA_API_TOKEN: ${{ secrets.CONDA }}
46+
run: |
47+
conda install anaconda-client
48+
anaconda upload --label main win-64/*.tar.bz2

.github/workflows/python-publish.yml

Lines changed: 20 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -5,82 +5,26 @@ on:
55
types: [created, edited]
66

77
jobs:
8-
flake8:
9-
runs-on: ubuntu-latest
10-
steps:
11-
- uses: actions/checkout@v2
12-
- name: Set up Python
13-
uses: actions/setup-python@v1
14-
with:
15-
python-version: 3.8
16-
- name: Install dependencies
17-
run: |
18-
python -m pip install --upgrade pip
19-
pip install flake8
20-
- name: Lint with flake8 for syntax errors
21-
run: |
22-
pip install flake8
23-
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
24-
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
25-
manylinux:
26-
runs-on: ubuntu-latest
27-
needs: flake8
28-
steps:
29-
- uses: actions/checkout@v2
30-
- name: Set up Python
31-
uses: actions/setup-python@v1
32-
with:
33-
python-version: 3.8
34-
- name: Install dependencies
35-
run: |
36-
python -m pip install --upgrade pip
37-
pip install twine
38-
- name: Build manylinux Python wheels
39-
uses: RalfG/python-wheels-manylinux-build@v0.2.2-manylinux2010_x86_64
40-
with:
41-
python-versions: 'cp36-cp36m cp37-cp37m cp38-cp38'
42-
build-requirements: 'cython numpy scipy scikit-learn'
43-
system-packages: ''
44-
package-path: ''
45-
pip-wheel-args: '--no-deps'
46-
- name: Publish wheels to PyPI
47-
env:
48-
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
49-
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
50-
run: |
51-
twine upload wheelhouse/*-manylinux*.whl
52-
53-
54-
build-windows:
55-
runs-on: windows-latest
56-
needs: flake8
8+
build_wheels_macos:
9+
name: Build wheels
10+
runs-on: ${{ matrix.os }}
5711
strategy:
5812
matrix:
59-
python: ['3.6','3.7','3.8']
13+
os: [ubuntu-latest, windows-latest, macos-latest]
6014
steps:
61-
- uses: actions/checkout@v2
62-
- uses: conda-incubator/setup-miniconda@v2
63-
with:
64-
python-version: ${{ matrix.python }}
65-
activate-environment: loop
66-
- name: Installing dependencies
67-
shell: bash -l {0}
68-
run: |
69-
python --version
70-
pip install -r requirements.txt
71-
conda info
72-
conda list
73-
- name: Building Loop wheel and installing
74-
shell: bash -l {0}
75-
run: |
76-
python setup.py bdist_wheel
77-
python setup.py bdist
78-
- name: Publish wheels to PyPI
79-
env:
80-
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
81-
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
82-
shell: bash -l {0}
83-
run : |
84-
pip install twine
85-
twine upload dist/*.whl
86-
15+
- uses: actions/checkout@v2
16+
17+
- name: Build wheels
18+
uses: joerick/cibuildwheel@v1.10.0
19+
env:
20+
CIBW_ARCHS_MACOS: x86_64 universal2
21+
CIBW_BUILD: "cp36-* cp37-* cp38-* cp39-*"
22+
CIBW_BEFORE_BUILD: "pip install numpy==1.18 cython" #make sure numpy is the same version as required by LS
23+
24+
- name: Publish wheels to PyPI
25+
env:
26+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
27+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
28+
run : |
29+
pip install twine
30+
python -m twine upload ./wheelhouse/*.whl

LoopStructural/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
ch.setFormatter(formatter)
3030
ch.setLevel(logging.WARNING)
3131
loggers = {}
32-
__version__ = '1.0.83'
32+
__version__ = '1.0.89'
3333
from .modelling.core.geological_model import GeologicalModel
3434
from .utils import log_to_console, log_to_file, getLogger
3535
logger = getLogger(__name__)

conda/conda_build

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
python:
2+
- 3.6
3+
- 3.7
4+
- 3.8
5+
- 3.9

0 commit comments

Comments
 (0)