diff --git a/.github/workflows/downstream.yml b/.github/workflows/downstream.yml index ed52c60..2257c88 100644 --- a/.github/workflows/downstream.yml +++ b/.github/workflows/downstream.yml @@ -18,7 +18,49 @@ on: - '*' jobs: - skeleton: - runs-on: ubuntu-latest + downstream: + name: downstream-${{matrix.name}}-${{matrix.platform}} + strategy: + fail-fast: false + matrix: + name: [re2, nokogiri, sqlite3] + platform: [ubuntu-latest, windows-latest, macos-latest] + include: + - name: re2 + url: https://github.com/mudge/re2 + command: "bundle exec rake compile spec" + ruby: "3.3" + - name: nokogiri + url: https://github.com/sparklemotion/nokogiri + command: "bundle exec rake compile test" + ruby: "3.3" + - name: sqlite3 + url: https://github.com/sparklemotion/sqlite3-ruby + command: "bundle exec rake compile test" + ruby: "3.3" + runs-on: ${{matrix.platform}} steps: - - run: echo hello world + - name: configure git crlf + if: ${{ startsWith(matrix.platform, 'windows') }} + run: | + git config --system core.autocrlf false + git config --system core.eol lf + - uses: actions/checkout@v4 + - uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{matrix.ruby}} + bundler-cache: true + bundler: latest + - run: git clone --depth=1 ${{matrix.url}} ${{matrix.name}} + - uses: actions/cache@v4 + with: + path: ${{matrix.name}}/ports/archives + key: tarballs-${{matrix.name}} + enableCrossOsArchive: true + - name: ${{matrix.name}} test suite + working-directory: ${{matrix.name}} + run: | + bundle remove mini_portile2 || true + bundle add mini_portile2 --path=".." + bundle install --local || bundle install + ${{matrix.command}}