Skip to content

Commit

Permalink
Added base package (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
byrdie authored Oct 28, 2024
1 parent 7cfa7dd commit 8f922af
Show file tree
Hide file tree
Showing 4 changed files with 68 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/black.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Black

on:
push:
branches:
- main
pull_request:

jobs:
black:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: psf/black@stable
with:
options: "--check --verbose --diff"
src: "./optimize"
34 changes: 34 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Publish to PyPI

permissions:
id-token: write
contents: read

on:
release:
types: [published]

jobs:
publish:
name: Build and publish to PyPI
if: startsWith(github.ref, 'refs/tags')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
- name: Install pypa/build
run: >-
python -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
14 changes: 14 additions & 0 deletions .github/workflows/ruff.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Ruff

on:
push:
branches:
- main
pull_request:

jobs:
ruff:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: chartboost/ruff-action@v1
3 changes: 3 additions & 0 deletions optimize/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"""
Numba-accelerated minimization of objective functions.
"""

0 comments on commit 8f922af

Please sign in to comment.