Skip to content

Commit

Permalink
Set up CI pipeline with github actions.
Browse files Browse the repository at this point in the history
  • Loading branch information
tbenthompson committed Jan 12, 2021
1 parent 15fbfbb commit e15a48d
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Lint and Test

on: [push]

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

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Add conda to system path
run: |
# $CONDA is an environment variable pointing to the root of the miniconda directory
echo $CONDA/bin >> $GITHUB_PATH
- name: Install dependencies
run: |
conda env update --file environment.yml --name base
- name: Lint with flake8
run: |
flake8 .
- name: Check formatting with black
run: |
black .
- name: Test with pytest
run: |
py.test
9 changes: 9 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: cppimport
channels:
- conda-forge
dependencies:
- pybind11
- mako
- black
- pytest
- flake8

0 comments on commit e15a48d

Please sign in to comment.