Skip to content

Commit

Permalink
First commit (push necessary files from 3MFPython Repo)
Browse files Browse the repository at this point in the history
  • Loading branch information
vijaiaeroastro committed May 8, 2024
1 parent a08ba1a commit abf33d1
Show file tree
Hide file tree
Showing 10 changed files with 7,545 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Build, Test, and Publish Wheel

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Build wheel
run: |
pip install -r requirements.txt
python setup.py bdist_wheel
- name: Get wheel name
id: set_wheel_name
run: echo "::set-output name=wheel_name::$(ls dist/*.whl)"

- uses: actions/upload-artifact@v4
with:
name: wheel-artifact
path: dist/*.whl

publish:
needs: build
runs-on: ubuntu-latest
if: github.event_name == 'push' && github.ref == 'refs/heads/main'

steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Download wheel
uses: actions/download-artifact@v4
with:
name: wheel-artifact

- name: List files in the workspace
run: |
echo "Listing all files and directories in the workspace:"
ls -R
- name: Install dependencies
run: pip install twine

- name: Publish to PyPI
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: twine upload *.whl
3 changes: 3 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
include lib3mf/lib3mf.so
include lib3mf/lib3mf.dylib
include lib3mf/lib3mf.dll
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
lib3mf (Python)
=========

This repository will automatically assemble a Python library
based on every release of lib3MF and deploy it to Python Package Index
Loading

0 comments on commit abf33d1

Please sign in to comment.