Skip to content

Commit

Permalink
Use GitHub Actions to run CI (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf authored Sep 26, 2020
1 parent 2dba5d6 commit 6708268
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 14 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Run tests

on:
push:
branches:
- master
tags: '*'
pull_request:

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
julia-version: ['1.5', '1.0']
python-version: ['3.7', '3.8']
ipython-dep-name: ['ipython']
include:
- python-version: '3.8'
julia-version: '1.5'
ipython-dep-name: 'ipython-pre'
- python-version: '3.8'
julia-version: '1.5'
ipython-dep-name: 'ipython-dev'
fail-fast: false
name: Test
Julia ${{ matrix.julia-version }}
Python ${{ matrix.python-version }}
${{ matrix.ipython-dep-name }}
steps:
- uses: actions/checkout@v2
- name: Setup julia
uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.julia-version }}
- name: Setup python
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- uses: julia-actions/julia-buildpkg@v1
env:
PYTHON: python
- uses: julia-actions/julia-runtest@latest
env:
IPYTHON_JL_IPYTHON_DEP_NAME: ${{ matrix.ipython-dep-name }}
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v1
with:
file: ./lcov.info
flags: unittests
name: codecov-umbrella
10 changes: 5 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,20 @@ os:
julia:
- 1.0
- 1.3
- nightly
env:
- CONDA_JL_VERSION="2"
- CONDA_JL_VERSION="3"
- CONDA_JL_VERSION="3" IPYTHON_JL_IPYTHON_DEP_NAME="ipython-pre"
- CONDA_JL_VERSION="3" IPYTHON_JL_IPYTHON_DEP_NAME="ipython-dev"
notifications:
email: false

# Only build branches via PR to avoid running CI twice.
# https://docs.travis-ci.com/user/conditional-builds-stages-jobs
# https://docs.travis-ci.com/user/conditions-v1
if: branch = master OR tag IS present OR type != push

## uncomment the following lines to allow failures on nightly julia
## (tests will run but not make your overall status red)
matrix:
allow_failures:
- julia: nightly

coveralls: true
codecov: true
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ REPL = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb"
Compat = "2.0, 3.0"
Conda = "1.0"
PyCall = "1.16"
julia = "0.7, 1.0"
julia = "1.0"

[extras]
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Expand Down
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Launch IPython in Julia

[![Build Status][travis-img]][travis-url]
[![Build Status][ci-img]][ci-url]
[![Coverage Status][coveralls-img]][coveralls-url]
[![codecov.io][codecov-img]][codecov-url]

Expand All @@ -11,10 +11,8 @@
## Usage

Run `using IPython` and then type `.` in empty `julia>` prompt or run
`IPython.start_ipython()`. If you are using IPython 7.0 or above, you
can switch back to Julia REPL by `backspace` or `ctrl-h` key (like
other REPL modes). For older versions of IPython, exiting IPython as
usual (e.g., `ctrl-d`) brings you back to the Julia REPL. Re-entering
`IPython.start_ipython()`. You can switch back to Julia REPL by
`backspace` or `ctrl-h` key (like other REPL modes). Re-entering
IPython keeps the previous state. Use pre-defined `Main` object to
access Julia namespace from IPython. Use `py"..."` string macro to
access Python namespace from Julia.
Expand All @@ -31,7 +29,8 @@ First launch of IPython may be slow.

### Python

* IPython (7.0 or above is recommended)
* Python 3.7 or above
* IPython 7.0 or above


## Accessing Julia from Python
Expand Down Expand Up @@ -74,8 +73,8 @@ It also removes `Out[1]`. Note that above setting does not change
your normal IPython prompts.


[travis-img]: https://travis-ci.org/tkf/IPython.jl.svg?branch=master
[travis-url]: https://travis-ci.org/tkf/IPython.jl
[ci-img]: https://github.com/tkf/IPython.jl/workflows/Run%20tests/badge.svg
[ci-url]: https://github.com/tkf/IPython.jl/actions?query=workflow%3ARun+tests
[coveralls-img]: https://coveralls.io/repos/tkf/IPython.jl/badge.svg?branch=master&service=github
[coveralls-url]: https://coveralls.io/github/tkf/IPython.jl?branch=master
[codecov-img]: http://codecov.io/github/tkf/IPython.jl/coverage.svg?branch=master
Expand Down

0 comments on commit 6708268

Please sign in to comment.