-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔀 Merge branch 'bundle_deepicedrain' (#37)
Closes #37 Bundle deepicedrain components into a Python package.
- Loading branch information
Showing
16 changed files
with
500 additions
and
747 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,69 @@ | ||
name: Test DeepIceDrain package | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
test: | ||
name: ${{ matrix.os }} - Python ${{ matrix.python_version }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
max-parallel: 1 | ||
fail-fast: false | ||
matrix: | ||
python_version: [3.8] | ||
os: [ubuntu-latest] | ||
|
||
steps: | ||
- name: Checkout current git repository | ||
uses: actions/[email protected] | ||
|
||
- name: Setup Miniconda | ||
uses: goanpeca/[email protected] | ||
with: | ||
miniconda-version: py38_4.8.2 | ||
activate-environment: deepicedrain | ||
python-version: ${{ matrix.python-version }} | ||
channels: conda-forge | ||
show-channel-urls: true | ||
auto-activate-base: false | ||
use-only-tar-bz2: true | ||
|
||
- name: Cache virtual environment | ||
uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: | | ||
/usr/share/miniconda3/envs/deepicedrain | ||
key: cache-venv-${{ github.ref }}-${{ hashFiles('**/environment.yml') }}-${{ hashFiles('**/poetry.lock') }} | ||
restore-keys: | | ||
cache-venv-refs/heads/master- | ||
- name: Install conda dependencies | ||
shell: bash -l {0} | ||
run: conda env update -n deepicedrain -f environment.yml | ||
if: steps.cache.outputs.cache-hit != 'true' | ||
|
||
- name: Install Poetry python dependencies | ||
shell: bash -l {0} | ||
run: poetry install | ||
if: steps.cache.outputs.cache-hit != 'true' | ||
|
||
- name: Display virtualenv and installed package information | ||
shell: bash -l {0} | ||
run: | | ||
conda info | ||
conda list | ||
poetry env info | ||
poetry show | ||
- name: Code Quality | ||
shell: bash -l {0} | ||
run: poetry run black . --check | ||
|
||
- name: Test with pytest | ||
shell: bash -l {0} | ||
run: poetry run pytest --verbose tests/ |
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,28 @@ | ||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# Distribution / packaging | ||
.Python | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
pip-wheel-metadata/ | ||
share/python-wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
MANIFEST | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints |
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
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.