-
Notifications
You must be signed in to change notification settings - Fork 228
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Explicit migration from Travis to Github actions + deps bump (#152)
* Explicit Travis replacement with github actions * Resolving config issues and linting * Who looks at examples, eh? * Bump version to 1.6.0
- Loading branch information
1 parent
0e28c29
commit 9f42c57
Showing
17 changed files
with
145 additions
and
162 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 |
---|---|---|
@@ -1,26 +1,13 @@ | ||
name: Linter | ||
|
||
on: [push] | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
build-n-lint: | ||
lint: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v4 | ||
- uses: psf/black@stable | ||
- uses: isort/isort-action@v1 | ||
with: | ||
python-version: "3.8" | ||
|
||
- name: Install test dependencies | ||
run: | | ||
pip install --upgrade pip | ||
pip install --only-binary=numpy,scipy numpy scipy | ||
pip install -e .[dev] | ||
- name: Run ISort check | ||
run: python -m isort --check PyEMD | ||
- name: Run PyCodeStyle check | ||
run: python -m pycodestyle PyEMD | ||
- name: Run Black check | ||
run: python -m black --check PyEMD | ||
sort-paths: PyEMD |
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,52 @@ | ||
name: Upload Python Package | ||
|
||
on: | ||
push: | ||
paths: | ||
- PyEMD/__init__.py | ||
branches: | ||
- $default-branch | ||
|
||
jobs: | ||
build-n-test: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
python-version: [3.8, 3.9, 3.10, 3.11, 3.12] | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Running Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install test dependencies | ||
run: | | ||
pip install --only-binary=numpy,scipy numpy scipy | ||
pip install -e .[test] | ||
- name: Run tests | ||
run: | | ||
python -m PyEMD.tests.test_all | ||
deploy: | ||
# Run 'deploy' job only if `PyEMD/__init__.py` is modified | ||
if: github.event_name == 'push' && contains(github.event.head_commit.modified, 'PyEMD/__init__.py') | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.x" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install build | ||
- name: Build package | ||
run: python -m build | ||
- name: Publish package | ||
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.EMD_PYPI_API_TOKEN }} |
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,37 @@ | ||
name: Test | ||
|
||
on: | ||
push: | ||
branches-ignore: | ||
- $default-branch | ||
pull_request: | ||
paths: | ||
- 'PyEMD/**.py' | ||
|
||
jobs: | ||
|
||
build-n-test: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
python-version: | ||
- "3.8" | ||
- "3.9" | ||
- "3.10" | ||
- "3.11" | ||
- "3.12" | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Running Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install test dependencies | ||
run: | | ||
pip install --only-binary=numpy,scipy numpy scipy | ||
pip install -e .[test] | ||
- name: Run tests | ||
run: | | ||
python -m PyEMD.tests.test_all |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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
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 |
---|---|---|
@@ -1,4 +1,5 @@ | ||
"""Calculate the statistical Significance of IMFs.""" | ||
|
||
import logging | ||
import math | ||
|
||
|
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 |
---|---|---|
@@ -1,4 +1,5 @@ | ||
"""Tests for checks.py.""" | ||
|
||
import unittest | ||
|
||
import numpy as np | ||
|
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
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
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
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
Oops, something went wrong.