-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit b9f422a
Showing
115 changed files
with
8,686 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Count lines of code for the project, and upload to the badge store | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'master' | ||
|
||
jobs: | ||
count-loc-and-upload: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- id: loc | ||
name: Count lines of code | ||
uses: Sh1nku/count-loc-action@v1 | ||
with: | ||
excluded: "*.xml,*.toml,*.yml" | ||
- uses: Sh1nku/badgestore-update-badge-action@v1 | ||
name: Update badge | ||
id: badge | ||
with: | ||
right-label: ${{ steps.loc.outputs.Total_code_abbreviated }} | ||
read-write-key: ${{ secrets.LOC_COUNT_BADGE_RW_KEY }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
# This file is autogenerated by maturin v1.1.0 | ||
# To update, run | ||
# | ||
# maturin generate-ci github -m ./wrappers/python/Cargo.toml | ||
# | ||
name: Create python wheels | ||
|
||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
target: [x86_64, x86, aarch64, armv7, s390x, ppc64le] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Build wheels | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
target: ${{ matrix.target }} | ||
args: --release --out dist --find-interpreter --manifest-path ./wrappers/python/Cargo.toml | ||
sccache: 'true' | ||
manylinux: auto | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wheels | ||
path: dist | ||
|
||
windows: | ||
runs-on: windows-latest | ||
strategy: | ||
matrix: | ||
target: [x64, x86] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
architecture: ${{ matrix.target }} | ||
- name: Build wheels | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
target: ${{ matrix.target }} | ||
args: --release --out dist --find-interpreter --manifest-path ./wrappers/python/Cargo.toml | ||
sccache: 'true' | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wheels | ||
path: dist | ||
|
||
macos: | ||
runs-on: macos-latest | ||
strategy: | ||
matrix: | ||
target: [x86_64, aarch64] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Build wheels | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
target: ${{ matrix.target }} | ||
args: --release --out dist --find-interpreter --manifest-path ./wrappers/python/Cargo.toml | ||
sccache: 'true' | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wheels | ||
path: dist | ||
|
||
sdist: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build sdist | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
command: sdist | ||
args: --out dist --manifest-path ./wrappers/python/Cargo.toml | ||
- name: Upload sdist | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wheels | ||
path: dist | ||
|
||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
if: "startsWith(github.ref, 'refs/tags/')" | ||
needs: [linux, windows, macos, sdist] | ||
steps: | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: wheels | ||
- name: Publish to PyPI | ||
uses: PyO3/maturin-action@v1 | ||
env: | ||
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }} | ||
with: | ||
command: upload | ||
args: --skip-existing * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Test python wrapper | ||
on: [push] | ||
jobs: | ||
checks: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [ "3.8", "3.11" ] | ||
docker-version: [ "8_11", "9_3" ] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Update Rust | ||
run: | | ||
rustup override set stable | ||
rustup update stable | ||
- name: Set up venv | ||
working-directory: ./wrappers/python | ||
run: | | ||
python -m venv venv | ||
- name: Install dependencies | ||
run: | | ||
source venv/bin/activate | ||
pip3 install -r requirements-dev.txt | ||
working-directory: ./wrappers/python | ||
- name: Install module | ||
run: | | ||
source venv/bin/activate | ||
maturin develop | ||
working-directory: ./wrappers/python | ||
- name: Start docker containers | ||
run: docker-compose up -d | ||
working-directory: ./docker/${{ matrix.docker-version }} | ||
- name: Run tests | ||
working-directory: ./wrappers/python | ||
run: | | ||
source venv/bin/activate | ||
pytest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Unit tests, linting, and formatting | ||
on: [push] | ||
jobs: | ||
checks: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
docker-version: [ "8_11", "9_3" ] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Update Rust | ||
run: | | ||
rustup override set stable | ||
rustup update stable | ||
- name: Start docker containers | ||
run: docker-compose up -d | ||
working-directory: ./docker/${{ matrix.docker-version }} | ||
- name: Run tests | ||
run: cargo test --all-features | ||
- name: Lint | ||
run: cargo clippy | ||
- name: Check formatting | ||
run: cargo fmt --check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/target | ||
/Cargo.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[workspace] | ||
|
||
members = [ | ||
"framework", | ||
"wrappers/python", | ||
] |
Oops, something went wrong.