rb/thrift: passe string field name value instead symbol #118
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ci | |
| on: | |
| push: | |
| pull_request: | |
| jobs: | |
| test: | |
| name: Test libraries | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: lib/go/test/go.mod | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: '3.3' | |
| working-directory: lib/rb | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get install -y \ | |
| automake \ | |
| bison \ | |
| cmake \ | |
| flex \ | |
| libboost-dev \ | |
| libboost-test-dev \ | |
| libboost-filesystem-dev \ | |
| libboost-program-options-dev \ | |
| libboost-thread-dev \ | |
| libboost-chrono-dev \ | |
| libboost-system-dev \ | |
| libevent-dev \ | |
| libssl-dev \ | |
| zlib1g-dev | |
| - name: Build thrift compiler | |
| run: | | |
| cmake \ | |
| -DTHRIFT_VERSION=0.0.1-upfluence \ | |
| -DBUILD_COMPILER=ON \ | |
| -DBUILD_LIBRARIES=OFF \ | |
| -DBUILD_TESTING=OFF \ | |
| -DBUILD_TUTORIALS=OFF \ | |
| -DTYPES_PREFIX=${HOME} \ | |
| -DBUILD_EXAMPLES=OFF | |
| cmake --build . --config Release | |
| - name: Test thrift compiler | |
| run: | | |
| cmake \ | |
| -DTHRIFT_VERSION=0.0.1-upfluence \ | |
| -DBUILD_COMPILER=ON \ | |
| -DBUILD_LIBRARIES=OFF \ | |
| -DBUILD_TESTING=OFF \ | |
| -DBUILD_COMPILER_TESTING=ON \ | |
| -DBUILD_TUTORIALS=OFF \ | |
| -DTYPES_PREFIX=${HOME} \ | |
| -DBUILD_EXAMPLES=OFF \ | |
| -DTHRIFT_COMPILER=$(pwd)/bin/thrift \ | |
| -S . -B build_test | |
| cmake --build build_test --config Release | |
| ctest --test-dir build_test/compiler/cpp -V | |
| - name: Configure | |
| run: | | |
| touch AUTHORS ChangeLog NEWS | |
| autoreconf -if | |
| ./configure --with-cpp --with-ruby --with-go | |
| - name: Check lib | |
| run: make -C lib check THRIFT=$(pwd)/bin/thrift | |
| - name: Check test | |
| run: make -C lib/cpp all && make -C test check THRIFT=$(pwd)/bin/thrift | |
| compute-version: | |
| runs-on: ubuntu-24.04 | |
| needs: test | |
| if: github.ref == 'refs/heads/master' | |
| outputs: | |
| version: ${{ steps.bump-version.outputs.version }} | |
| steps: | |
| - name: Bump version | |
| id: bump-version | |
| uses: upfluence/actions/bump-version@master | |
| build: | |
| name: Build the thrift compiler | |
| needs: compute-version | |
| if: github.ref == 'refs/heads/master' | |
| strategy: | |
| matrix: | |
| os: [ubuntu-24.04, macos-26-intel, macos-26] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| - name: Install dependencies (ubuntu) | |
| if: startsWith(matrix.os, 'ubuntu') | |
| run: sudo apt-get install -y libboost-dev | |
| - name: Install dependencies (macos) | |
| if: startsWith(matrix.os, 'macos') | |
| run: | | |
| brew install boost bison flex | |
| echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH | |
| - name: Generate build configuration | |
| env: | |
| THRIFT_VERSION: ${{ needs.compute-version.outputs.version }} | |
| run: | | |
| cmake \ | |
| -DTHRIFT_VERSION=${THRIFT_VERSION#v}-upfluence \ | |
| -DBUILD_COMPILER=ON \ | |
| -DBUILD_LIBRARIES=OFF \ | |
| -DBUILD_SHARED_LIBS=OFF \ | |
| -DWITH_OPENSSL=OFF \ | |
| -DBUILD_TESTING=OFF \ | |
| -DBUILD_TUTORIALS=OFF \ | |
| -DTYPES_PREFIX=${HOME} \ | |
| -DBUILD_EXAMPLES=OFF | |
| - name: Build | |
| run: | | |
| cmake --build . --config Release | |
| mv bin/thrift bin/thrift-${{ matrix.os }} | |
| - name: Upload Binary | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: thrift-${{ matrix.os }} | |
| retention-days: 2 | |
| path: bin/* | |
| release: | |
| name: "Release binaries" | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - compute-version | |
| - build | |
| if: github.ref == 'refs/heads/master' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: thrift-ubuntu-24.04 | |
| path: dist/ | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: thrift-macos-26-intel | |
| path: dist/ | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: thrift-macos-26 | |
| path: dist/ | |
| - name: tar types | |
| run: | | |
| tar -cvf dist/types.tar types | |
| - name: move thrift-docker | |
| run: | | |
| cp contrib/thrift-docker dist | |
| - name: Login to GitHub Container Registry | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build docker container | |
| uses: upfluence/actions/build-docker@master | |
| with: | |
| version: ${{ needs.compute-version.outputs.version }} | |
| registries: ghcr.io | |
| - name: Create release | |
| uses: upfluence/actions/create-github-release@master | |
| with: | |
| attachments: dist/* | |
| version: ${{ needs.compute-version.outputs.version }} | |