Skip to content

Commit 69a84a7

Browse files
committed
initial commit
0 parents  commit 69a84a7

31 files changed

Lines changed: 3544 additions & 0 deletions

.github/workflows/ci.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main, test]
6+
tags: [v*]
7+
pull_request:
8+
9+
jobs:
10+
test:
11+
strategy:
12+
matrix:
13+
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12'] # Specify the Python versions you want to test against
14+
os: [ubuntu-latest, windows-latest]
15+
name: Python ${{ matrix.python-version }} - ${{ matrix.os }}
16+
runs-on: ${{ matrix.os }}
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
- name: Set up Python
21+
uses: actions/setup-python@v4
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
pip install numpy
28+
- name: Run tests
29+
run: |
30+
python -m tests.run_tests

.github/workflows/format.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Format
2+
3+
on:
4+
push:
5+
branches: [main]
6+
tags: [v*]
7+
pull_request:
8+
9+
jobs:
10+
format:
11+
name: "Format Check"
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v4
16+
- name: Set up Python
17+
uses: actions/setup-python@v4
18+
with:
19+
python-version: '3.x'
20+
- name: Install black
21+
run: |
22+
python -m pip install --upgrade pip
23+
pip install black
24+
- name: Format code with black
25+
run: |
26+
black . --check
27+
- name: Suggest formatting changes
28+
uses: reviewdog/action-suggester@v1
29+
if: github.event_name == 'pull_request'
30+
with:
31+
tool_name: black
32+
fail_on_error: true

.github/workflows/release.yml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
name: Publish Python release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*.*.*' # Only run for version tags
7+
paths:
8+
- 'pyproject.toml' # Ensure the project details have been changed
9+
10+
jobs:
11+
build:
12+
name: Build distribution
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
- name: Set up Python
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.x"
20+
- name: Install pypa/build
21+
run: >-
22+
python3 -m
23+
pip install
24+
build
25+
--user
26+
- name: Build a binary wheel and a source tarball
27+
run: python3 -m build
28+
- name: Store the distribution packages
29+
uses: actions/upload-artifact@v3
30+
with:
31+
name: python-package-distributions
32+
path: dist/
33+
34+
github-release:
35+
name: >-
36+
Sign distribution and upload to GitHub
37+
needs:
38+
- build
39+
runs-on: ubuntu-latest
40+
permissions:
41+
contents: write
42+
id-token: write
43+
steps:
44+
- name: Download the dists
45+
uses: actions/download-artifact@v3
46+
with:
47+
name: python-package-distributions
48+
path: dist/
49+
- name: Sign the dists
50+
uses: sigstore/gh-action-sigstore-python@v2.1.1
51+
with:
52+
inputs: >-
53+
./dist/*.tar.gz
54+
./dist/*.whl
55+
- name: Create GitHub Release
56+
env:
57+
GITHUB_TOKEN: ${{ github.token }}
58+
run: >-
59+
gh release create
60+
'${{ github.ref_name }}'
61+
--repo '${{ github.repository }}'
62+
--notes ""
63+
- name: Upload artifact signatures to GitHub Release
64+
env:
65+
GITHUB_TOKEN: ${{ github.token }}
66+
run: >-
67+
gh release upload
68+
'${{ github.ref_name }}' dist/**
69+
--repo '${{ github.repository }}'
70+

.github/workflows/sphinx.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: "Sphinx: Render docs"
2+
3+
on: push
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
permissions:
9+
contents: write
10+
steps:
11+
- uses: actions/checkout@v4
12+
- name: Build HTML
13+
uses: ammaraskar/sphinx-action@master
14+
- name: Upload artifacts
15+
uses: actions/upload-artifact@v4
16+
with:
17+
name: html-docs
18+
path: docs/build/html/
19+
- name: Deploy
20+
uses: peaceiris/actions-gh-pages@v3
21+
if: github.ref == 'refs/heads/main'
22+
with:
23+
github_token: ${{ secrets.GITHUB_TOKEN }}
24+
publish_dir: docs/build/html

.gitignore

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
.vscode/
2+
build/
3+
dist/
4+
*.egg-info/
5+
*.egg
6+
*.py[cod]
7+
__pycache__/
8+
venv/
9+
10+
bin/
11+
/lib64/
12+
pyvenv.cfg
13+
/lib/
14+
src/pyNFFT3/lib/AVX2/libfftw3-3.dll
15+
src/pyNFFT3/lib/AVX2/libgomp-1.dll
16+
src/pyNFFT3/lib/AVX2/libgcc_s_seh-1.dll
17+
src/pyNFFT3/lib/AVX2/libwinpthread-1.dll

0 commit comments

Comments
 (0)