From 483a2f53e4f6b9eedda3d816ddf3866610c54166 Mon Sep 17 00:00:00 2001 From: Crayon2000 Date: Sun, 26 Jan 2020 12:37:39 -0500 Subject: [PATCH] Use GitHub actions instead of Travis CI --- .github/workflows/ci.yml | 31 ++++++++++++++++++++++++++ .github/workflows/doc.yml | 35 +++++++++++++++++++++++++++++ .travis.yml | 47 --------------------------------------- README.md | 2 +- 4 files changed, 67 insertions(+), 48 deletions(-) create mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/doc.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..7c0d3f4 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,31 @@ +name: Continuous Integration + +on: [push, pull_request] + +jobs: + + build: + name: Build + runs-on: ubuntu-latest + env: + DEVKITPRO: /opt/devkitpro + DEVKITPPC: ${DEVKITPRO}/devkitPPC + + steps: + + - name: Checkout the Git repository + uses: actions/checkout@v2 + + - name: Download and install devkitPro + run: | + wget -nv https://github.com/devkitPro/pacman/releases/download/devkitpro-pacman-1.0.1/devkitpro-pacman.deb + sudo dpkg --install devkitpro-pacman.deb + + - name: Install required packages + run: sudo dkp-pacman --sync --sysupgrade --refresh --needed --noconfirm wii-dev ppc-libpng ppc-freetype ppc-libjpeg-turbo + + - name: Build library and examples + run: | + (cd GRRLIB && sudo -E make clean all install) + (cd examples && make) + (cd GRRLIB && sudo -E make PLATFORM=cube clean all) diff --git a/.github/workflows/doc.yml b/.github/workflows/doc.yml new file mode 100644 index 0000000..53055f1 --- /dev/null +++ b/.github/workflows/doc.yml @@ -0,0 +1,35 @@ +name: Documentation + +on: + push: + branches: + - master + +jobs: + + doc: + name: Deploy documentation + runs-on: ubuntu-latest + + steps: + + - name: Checkout the Git repository + uses: actions/checkout@v2 + + - name: Install doxygen + run: | + sudo apt-get update + sudo apt-get install doxygen doxygen-latex graphviz + + - name: Generate documentaion + run: | + doxygen grrlib.doxygen >/dev/null + make --directory=latex >/dev/null + touch doc/.nojekyll + mv latex/refman.pdf doc/PDF-documentation.pdf + + - name: Deploy to GitHub Pages + uses: maxheld83/ghpages@v0.2.1 + env: + BUILD_DIR: ./doc + GH_PAT: ${{ secrets.GH_PAT }} diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5a1a91e..0000000 --- a/.travis.yml +++ /dev/null @@ -1,47 +0,0 @@ -language: c -dist: bionic -sudo: required - -os: - - linux - -env: - global: - - DEVKITPRO=/opt/devkitpro - - DEVKITPPC=${DEVKITPRO}/devkitPPC - -addons: - apt: - packages: - - doxygen - - doxygen-latex - -cache: - directories: - - ${DEVKITPRO} - -before_install: - - wget https://github.com/devkitPro/pacman/releases/download/devkitpro-pacman-1.0.1/devkitpro-pacman.deb - -install: - - sudo dpkg --install devkitpro-pacman.deb - - sudo dkp-pacman --sync --sysupgrade --refresh --needed --noconfirm wii-dev ppc-libpng ppc-freetype ppc-libjpeg-turbo - -script: - - (cd GRRLIB && sudo -E make clean all install) - - (cd examples && make) - - (cd GRRLIB && sudo -E make PLATFORM=cube clean all) - - doxygen grrlib.doxygen >/dev/null - - make --directory=latex >/dev/null - -before_deploy: - - touch doc/.nojekyll - - mv latex/refman.pdf doc/PDF-documentation.pdf - -deploy: - provider: pages - skip_cleanup: true - local_dir: doc - github_token: $GITHUB_TOKEN - on: - branch: master diff --git a/README.md b/README.md index 55cafda..fafbb26 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # GRRLIB -[![Build Status](https://travis-ci.org/GRRLIB/GRRLIB.svg?branch=master)](https://travis-ci.org/GRRLIB/GRRLIB) +[![Continuous Integration](https://github.com/GRRLIB/GRRLIB/workflows/Continuous%20Integration/badge.svg)](https://github.com/GRRLIB/GRRLIB/actions) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/5b2983faefbf443eaa5705e7cc6e5f68)](https://www.codacy.com/app/Crayon2000/GRRLIB?utm_source=github.com&utm_medium=referral&utm_content=GRRLIB/GRRLIB&utm_campaign=Badge_Grade) [![Join the chat at https://gitter.im/GRRLIB/GRRLIB](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/GRRLIB/GRRLIB?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)