From 9913ed2930bd79301239dc55773c4e7b74c25ea9 Mon Sep 17 00:00:00 2001 From: Kenta Murata Date: Mon, 28 Dec 2020 12:19:19 +0900 Subject: [PATCH 1/5] CI: Stop using Travis CI --- .travis.yml | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 38a85841..00000000 --- a/.travis.yml +++ /dev/null @@ -1,21 +0,0 @@ -# Passes arguments to bundle install (http://gembundler.com/man/bundle-install.1.html) -#bundler_args: --binstubs -language: ruby - -# Specify which ruby versions you wish to run your tests on, each version will be used -rvm: - - 2.3 - - 2.4 - - 2.5 - - 2.6 - - 2.7 - - ruby-head - - jruby-9.1 # Ruby 2.3 - - jruby-9.2 # Ruby 2.5 - - truffleruby -matrix: - allow_failures: - - rvm: ruby-head - - rvm: truffleruby -script: "bundle exec rake" -sudo: false From 44476539de1f098bd5a77f236a0c9a44d6a5ea5c Mon Sep 17 00:00:00 2001 From: Kenta Murata Date: Mon, 28 Dec 2020 12:19:38 +0900 Subject: [PATCH 2/5] CI: Use GitHub Actions for CI --- .github/workflows/ci.yml | 55 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..1c240d45 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,55 @@ +name: CI + +on: +- push +- pull_request + +jobs: + host: + name: ${{ matrix.os }} ${{ matrix.ruby }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: + - ubuntu-20.04 + - ubuntu-18.04 + - macos-11.0 + - macos-10.15 + - windows-latest + ruby: + - 3.0 + - 2.7 + - 2.6 + - 2.5 + - 2.4 + - 2.3 + - debug + include: + - { os: windows-latest , ruby: mingw } + - { os: windows-latest , ruby: mswin } + - { os: ubuntu-latest , ruby: jruby-9.1 } # Ruby 2.3 + - { os: ubuntu-latest , ruby: jruby-9.2 } # Ruby 2.5 + - { os: ubuntu-latest , ruby: truffleruby } + exclude: + - { os: windows-latest , ruby: 3.0 } + - { os: windows-latest , ruby: debug } + + steps: + - uses: actions/checkout@v2 + + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby }} + + - run: bundle install + + - run: rake compile + + - run: rake test + + - run: rake build + + - run: gem install pkg/*.gem + From e5926922e3e8dff3b446ec16e7cd5ccdc922ac4b Mon Sep 17 00:00:00 2001 From: Kenta Murata Date: Mon, 28 Dec 2020 12:25:39 +0900 Subject: [PATCH 3/5] CI: Install ragel on macOS --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1c240d45..e8ce3d99 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,6 +43,9 @@ jobs: with: ruby-version: ${{ matrix.ruby }} + - run: brew install ragel + if: ${{ startsWith(matrix.os, 'macos') }} + - run: bundle install - run: rake compile From 3b13e75b11f3790f16149a21461767b67dece9f0 Mon Sep 17 00:00:00 2001 From: Kenta Murata Date: Mon, 28 Dec 2020 12:29:04 +0900 Subject: [PATCH 4/5] CI: Install ragel on Ubuntu --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e8ce3d99..2215eb19 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,6 +43,9 @@ jobs: with: ruby-version: ${{ matrix.ruby }} + - run: sudo apt install ragel + if: ${{ startsWith(matrix.os, 'ubuntu') }} + - run: brew install ragel if: ${{ startsWith(matrix.os, 'macos') }} From 949cdaa6006eb4f95d3870071025d3bf35e525f9 Mon Sep 17 00:00:00 2001 From: Kenta Murata Date: Mon, 28 Dec 2020 12:30:06 +0900 Subject: [PATCH 5/5] CI: Specify the version 3.0 as a String --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2215eb19..c278a1cc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,7 +18,7 @@ jobs: - macos-10.15 - windows-latest ruby: - - 3.0 + - '3.0' - 2.7 - 2.6 - 2.5 @@ -32,7 +32,7 @@ jobs: - { os: ubuntu-latest , ruby: jruby-9.2 } # Ruby 2.5 - { os: ubuntu-latest , ruby: truffleruby } exclude: - - { os: windows-latest , ruby: 3.0 } + - { os: windows-latest , ruby: '3.0' } - { os: windows-latest , ruby: debug } steps: