Skip to content

Commit ab49631

Browse files
committed
Merge branch 'master' into future
2 parents 9dee8de + 3262c97 commit ab49631

23 files changed

+1072
-578
lines changed

.github/dev_requirements.txt

Lines changed: 0 additions & 14 deletions
This file was deleted.

.github/workflows/master.yml

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,18 @@ name: build
66

77
on:
88
push:
9-
branches: [ master ]
10-
pull_request:
11-
branches: [ master ]
9+
branches: [ master, future ]
10+
# pull_request:
11+
# branches: [ master ]
1212

1313
jobs:
1414
# Run tests on different versions of python
1515
unittest:
16-
runs-on: ubuntu-latest
16+
runs-on: ${{ matrix.os }}
1717
strategy:
1818
matrix:
19-
python-version: [3.6, 3.7, 3.8]
19+
os: [windows-latest, ubuntu-latest, macos-latest]
20+
python-version: [3.7, 3.8, 3.9]
2021

2122
steps:
2223
- uses: actions/checkout@v2
@@ -27,8 +28,7 @@ jobs:
2728
- name: Install dependencies
2829
run: |
2930
python -m pip install --upgrade pip
30-
pip install -r .github/dev_requirements.txt
31-
pip install .
31+
pip install .[dev]
3232
pip install pytest-timeout
3333
pip install pytest-xvfb
3434
- name: Test with pytest
@@ -51,10 +51,9 @@ jobs:
5151
- name: Install dependencies
5252
run: |
5353
python -m pip install --upgrade pip
54-
pip install -r .github/dev_requirements.txt
5554
- name: Run coverage
5655
run: |
57-
pip install .
56+
pip install .[dev]
5857
pip install pytest-xvfb
5958
pip install pytest-timeout
6059
pytest --cov --cov-config=./spatialmath/.coveragerc --cov-report xml
@@ -78,8 +77,7 @@ jobs:
7877
- name: Install dependencies
7978
run: |
8079
python -m pip install --upgrade pip
81-
pip install -r .github/dev_requirements.txt
82-
pip install .
80+
pip install .[dev,docs]
8381
pip install git+https://github.com/petercorke/sphinx-autorun.git
8482
pip install sympy
8583
sudo apt-get install graphviz

.github/workflows/publish.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# This workflows will upload a Python Package using Twine when a release is created
2+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3+
4+
# name: Upload Python Package
5+
6+
on:
7+
release:
8+
types: [created]
9+
workflow_dispatch:
10+
11+
jobs:
12+
deploy:
13+
14+
runs-on: ${{ matrix.os }}
15+
strategy:
16+
max-parallel: 2
17+
matrix:
18+
os: [ubuntu-latest]
19+
python-version: [3.8]
20+
21+
steps:
22+
- uses: actions/checkout@v2
23+
- name: Set up Python
24+
uses: actions/setup-python@v2
25+
with:
26+
python-version: ${{ matrix.python-version }}
27+
- name: Install dependencies
28+
run: |
29+
python -m pip install --upgrade pip
30+
pip install -U setuptools wheel twine
31+
- name: Build and publish
32+
env:
33+
TWINE_USERNAME: __token__
34+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
35+
run: |
36+
python setup.py sdist bdist_wheel
37+
ls ./dist/*.whl
38+
twine upload dist/*.gz
39+
twine upload dist/*.whl

setup.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,17 @@
1111
with open(path.join(here, "RELEASE"), encoding="utf-8") as f:
1212
release = f.read()
1313

14-
docs_req = ["sphinx", "sphinx_rtd_theme", "sphinx-autorun", "sphinxcontrib-jsmath"]
14+
docs_req = ["sphinx", "sphinx_rtd_theme", "sphinx-autorun", "sphinxcontrib-jsmath", "sphinx_markdown_tables"]
15+
16+
dev_req = [
17+
"sympy",
18+
"pytest",
19+
"pytest-cov",
20+
"coverage",
21+
"codecov",
22+
"recommonmark",
23+
"flake8"
24+
]
1525

1626
setup(
1727
name="spatialmath-python",
@@ -53,5 +63,6 @@
5363
install_requires=["numpy", "scipy", "matplotlib", "colored", "ansitable"],
5464
extras_require={
5565
"docs": docs_req,
66+
"dev": dev_req
5667
},
5768
)

spatialmath/base/__init__.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,7 @@
183183
"getunit",
184184
"isnumberlist",
185185
"isvectorlist",
186+
186187
# spatialmath.base.quaternions
187188
"pure",
188189
"qnorm",
@@ -206,6 +207,7 @@
206207
"dotb",
207208
"angle",
208209
"qprint",
210+
209211
# spatialmath.base.transforms2d
210212
"rot2",
211213
"trot2",
@@ -222,6 +224,7 @@
222224
"xyt2tr",
223225
"tr2xyt",
224226
"trinv2",
227+
225228
# spatialmath.base.transforms3d
226229
"rotx",
227230
"roty",
@@ -264,6 +267,7 @@
264267
"tranimate",
265268
"tr2x",
266269
"x2tr",
270+
267271
# spatialmath.base.transformsNd
268272
"t2r",
269273
"r2t",
@@ -282,6 +286,7 @@
282286
"e2h",
283287
"homtrans",
284288
"rodrigues",
289+
285290
# spatialmath.base.vectors
286291
"colvec",
287292
"unitvec",
@@ -301,9 +306,11 @@
301306
"iszero",
302307
"wrap_0_2pi",
303308
"wrap_mpi_pi",
309+
"wrap_0_pi",
304310
# spatialmath.base.animate
305311
"Animate",
306312
"Animate2",
313+
307314
# spatial.base.graphics
308315
"plotvol2",
309316
"plotvol3",
@@ -316,6 +323,7 @@
316323
"sphere",
317324
"ellipsoid",
318325
"plot_box",
326+
"plot_arrow",
319327
"plot_circle",
320328
"plot_ellipse",
321329
"plot_homline",
@@ -326,9 +334,13 @@
326334
"plot_cuboid",
327335
"axes_logic",
328336
"isnotebook",
337+
329338
# spatial.base.numeric
330339
"numjac",
331340
"numhess",
332341
"array2str",
333342
"bresenham",
343+
"mpq_point",
344+
"gauss1d",
345+
"gauss2d",
334346
]

0 commit comments

Comments
 (0)