diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index cfba9b6..0000000 --- a/.travis.yml +++ /dev/null @@ -1,68 +0,0 @@ -# R for travis: see documentation at https://docs.travis-ci.com/user/languages/r - -language: r -sudo: required - -os: - - linux - -dist: - - xenial - -r: - - oldrel - - release - - devel - -addons: - apt: - sources: - - deadsnakes - packages: - - libhdf5-dev - - python3.6-dev - -cache: - - packages - - apt - - directories: - - $HOME/.cache/pip - -before_install: - - curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py - - sudo python3.6 get-pip.py - - mkdir -p ~/bin && export PATH=~/bin/:$PATH - - ln -s $(which python3.6) ~/bin/python - - ln -s $(which pip3.6) ~/bin/pip - - sudo pip install --upgrade pip - - pip install --user -q phate - -install: - - cd python; pip install --user -q . - - cd ../Rmagic; R -e 'install.packages("devtools", repos="http://cloud.r-project.org")' - - R -e 'install.packages("BiocManager", repos="http://cloud.r-project.org"); BiocManager::install("multtest")' - - R -e 'devtools::install_deps(dep = T, upgrade="always")' - - cd .. - -script: - - python -c "import magic" - - cd Rmagic; R CMD build . - - R CMD check *tar.gz - - cd ../python; pip install --user -q .[test] - - if [ "$TRAVIS_PYTHON_VERSION" != "3.5" ]; then black . --check --diff -t py35; fi - - python setup.py test - - pip install --user -q .[doc] - - cd doc; make html; cd .. - -deploy: - provider: pypi - user: scottgigante - password: ${PYPI_PASSWORD} - distributions: sdist bdist_wheel - skip_existing: true - skip_cleanup: true - on: - tags: true - branch: master - -warnings_are_errors: true diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 17c75d4..11bfb4a 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -25,7 +25,7 @@ Code Style and Testing Contributors are encouraged to write tests for their code, but if you do not know how to do so, please do not feel discouraged from contributing code! Others can always help you test your contribution. -Python code style is dictated by [`black`](https://pypi.org/project/black/#installation-and-usage). To automatically reformat your code when you run `git commit`, you can run `./autoblack.sh` in the root directory of this project to add a hook to your `git` repository. +Code style is dictated by [`black`](https://pypi.org/project/black/#installation-and-usage) and [OpenStack](https://docs.openstack.org/hacking/latest/user/hacking.html#styleguide). Styling is automatically applied by [`pre-commit`](https://github.com/pre-commit/pre-commit). Code of Conduct --------------- diff --git a/README.md b/README.md index 77213fb..801c1d6 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ Markov Affinity-based Graph Imputation of Cells (MAGIC) [![Latest PyPI version](https://img.shields.io/pypi/v/magic-impute.svg)](https://pypi.org/project/magic-impute/) [![Latest CRAN version](https://img.shields.io/cran/v/Rmagic.svg)](https://cran.r-project.org/package=Rmagic) -[![Travis CI Build](https://api.travis-ci.com/KrishnaswamyLab/MAGIC.svg?branch=master)](https://travis-ci.com/KrishnaswamyLab/MAGIC) +[![GitHub Actions Build](https://img.shields.io/github/workflow/status/KrishnaswamyLab/MAGIC/Unit%20Tests/master?label=Github%20Actions)](https://github.com/KrishnaswamyLab/MAGIC/actions) [![Read the Docs](https://img.shields.io/readthedocs/magic.svg)](https://magic.readthedocs.io/) [![Cell Publication DOI](https://zenodo.org/badge/DOI/10.1016/j.cell.2018.05.061.svg)](https://www.cell.com/cell/abstract/S0092-8674(18)30724-4) [![Twitter](https://img.shields.io/twitter/follow/KrishnaswamyLab.svg?style=social&label=Follow)](https://twitter.com/KrishnaswamyLab) diff --git a/Rmagic/README.Rmd b/Rmagic/README.Rmd index 46c8f4b..1ab80fe 100644 --- a/Rmagic/README.Rmd +++ b/Rmagic/README.Rmd @@ -17,7 +17,7 @@ knitr::opts_chunk$set( [![Latest PyPI version](https://img.shields.io/pypi/v/magic-impute.svg)](https://pypi.org/project/magic-impute/) [![Latest CRAN version](https://img.shields.io/cran/v/Rmagic.svg)](https://cran.r-project.org/package=Rmagic) -[![Travis CI Build](https://api.travis-ci.com/KrishnaswamyLab/MAGIC.svg?branch=master)](https://travis-ci.com/KrishnaswamyLab/MAGIC) +[![GitHub Actions Build](https://img.shields.io/github/workflow/status/KrishnaswamyLab/MAGIC/Unit%20Tests/master?label=Github%20Actions)](https://github.com/KrishnaswamyLab/MAGIC/actions) [![Read the Docs](https://img.shields.io/readthedocs/magic.svg)](https://magic.readthedocs.io/) [![Cell Publication DOI](https://zenodo.org/badge/DOI/10.1016/j.cell.2018.05.061.svg)](https://www.cell.com/cell/abstract/S0092-8674(18)30724-4) [![Twitter](https://img.shields.io/twitter/follow/KrishnaswamyLab.svg?style=social&label=Follow)](https://twitter.com/KrishnaswamyLab) diff --git a/Rmagic/README.md b/Rmagic/README.md index 1779cbe..69fb231 100644 --- a/Rmagic/README.md +++ b/Rmagic/README.md @@ -10,7 +10,7 @@ toc: true [![Latest PyPI version](https://img.shields.io/pypi/v/magic-impute.svg)](https://pypi.org/project/magic-impute/) [![Latest CRAN version](https://img.shields.io/cran/v/Rmagic.svg)](https://cran.r-project.org/package=Rmagic) -[![Travis CI Build](https://api.travis-ci.com/KrishnaswamyLab/MAGIC.svg?branch=master)](https://travis-ci.com/KrishnaswamyLab/MAGIC) +[![GitHub Actions Build](https://img.shields.io/github/workflow/status/KrishnaswamyLab/MAGIC/Unit%20Tests/master?label=Github%20Actions)](https://github.com/KrishnaswamyLab/MAGIC/actions) [![Read the Docs](https://img.shields.io/readthedocs/magic.svg)](https://magic.readthedocs.io/) [![Cell Publication DOI](https://zenodo.org/badge/DOI/10.1016/j.cell.2018.05.061.svg)](https://www.cell.com/cell/abstract/S0092-8674(18)30724-4) [![Twitter](https://img.shields.io/twitter/follow/KrishnaswamyLab.svg?style=social&label=Follow)](https://twitter.com/KrishnaswamyLab) diff --git a/autoblack.sh b/autoblack.sh deleted file mode 100644 index f8c6210..0000000 --- a/autoblack.sh +++ /dev/null @@ -1,13 +0,0 @@ -cat <> .git/hooks/pre-commit -#!/bin/sh - -set -e - -files=\$(git diff --staged --name-only --diff-filter=d -- "*.py") - -for file in \$files; do - black -q -t py35 \$file - git add \$file -done -EOF -chmod +x .git/hooks/pre-commit diff --git a/python/README.rst b/python/README.rst index 11e4f33..40ac954 100644 --- a/python/README.rst +++ b/python/README.rst @@ -8,9 +8,9 @@ Markov Affinity-based Graph Imputation of Cells (MAGIC) .. image:: https://img.shields.io/cran/v/Rmagic.svg :target: https://cran.r-project.org/package=Rmagic :alt: Latest CRAN version -.. image:: https://api.travis-ci.com/KrishnaswamyLab/MAGIC.svg?branch=master - :target: https://travis-ci.com/KrishnaswamyLab/MAGIC - :alt: Travis CI Build +.. image:: https://img.shields.io/github/workflow/status/KrishnaswamyLab/MAGIC/Unit%20Tests/master?label=Github%20Actions + :target: https://github.com/KrishnaswamyLab/MAGIC/actions + :alt: GitHub Actions Build .. image:: https://img.shields.io/readthedocs/magic.svg :target: https://magic.readthedocs.io/ :alt: Read the Docs diff --git a/python/doc/source/index.rst b/python/doc/source/index.rst index b22df14..51873a7 100644 --- a/python/doc/source/index.rst +++ b/python/doc/source/index.rst @@ -12,7 +12,7 @@ MAGIC - Markov Affinity-based Graph Imputation of Cells .. raw:: html - Travis CI Build + GitHub Actions Build .. raw:: html