Skip to content

Commit

Permalink
WIP github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Böck committed Jan 26, 2022
1 parent b6ac118 commit 5871813
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 126 deletions.
92 changes: 0 additions & 92 deletions .github/workflows/ci.yml

This file was deleted.

65 changes: 65 additions & 0 deletions .github/workflows/python-package-conda.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Python Package using Conda

on: [push]

jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
max-parallel: 5

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.10
uses: actions/setup-python@v2
with:
python-version: "3.10"
- name: Install OS dependencies
shell: bash -l {0}
run: |
# get a working ffmpeg
sudo wget -O ffmpeg.tar.gz https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-amd64-static.tar.xz
sudo mkdir ffmpeg
sudo tar xvf ffmpeg.tar.gz -C ffmpeg --strip-components=1
sudo cp ffmpeg/ffmpeg ffmpeg/ffprobe /usr/bin/
# install system libraries
sudo apt-get update -yy
sudo apt-get install -yy libfftw3-dev
- name: Cache conda
uses: actions/cache@v2
env:
# Increase this value to reset cache if etc/example-environment.yml has not changed
CACHE_NUMBER: 1
with:
path: ~/conda_pkgs_dir
key: ${{ runner.os }}-${{ matrix.python-version }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles( matrix.envfile ) }}
- name: Install Conda env
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
add-pip-as-python-dependency: true
auto-activate-base: false
activate-environment: madmom
# channel-priority: ${{ matrix.channel-priority }}
environment-file: environment.yml
use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly!
- name: Conda info
shell: bash -l {0}
run: |
conda info -a
conda list
- name: Install madmom
shell: bash -l {0}
run: python -m pip install --upgrade-strategy only-if-needed -e .[tests]
# - name: Lint with flake8
# run: |
# conda install flake8
# # stop the build if there are Python syntax errors or undefined names
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
conda install pytest
pytest
34 changes: 0 additions & 34 deletions .github/workflows/python-package_conda.yml

This file was deleted.

0 comments on commit 5871813

Please sign in to comment.