# Auto-generated by Cimas: Do not edit it manually! # See https://github.com/metanorma/cimas name: rake on: push: branches: [ master, main ] tags: [ v* ] pull_request: jobs: rake: name: Test on Ruby ${{ matrix.ruby }} ${{ matrix.os }} runs-on: ${{ matrix.os }} continue-on-error: ${{ matrix.experimental }} strategy: fail-fast: false matrix: ruby: [ '2.6', '2.5', '2.4' ] os: [ ubuntu-latest, windows-latest, macos-latest ] experimental: [ false ] include: - ruby: '2.7' os: 'ubuntu-latest' experimental: true - ruby: '2.7' os: 'windows-latest' experimental: true - ruby: '2.7' os: 'macos-latest' experimental: true steps: - uses: actions/checkout@master - uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} - uses: actions/cache@v2 with: path: vendor/bundle key: bundle-${{ matrix.os }}-${{ matrix.ruby }}-${{ hashFiles('**/*.gemspec') }} restore-keys: bundle-${{ matrix.os }}-${{ matrix.ruby }} - run: bundle config set path 'vendor/bundle' - run: bundle install --jobs 4 --retry 3 - uses: actions/setup-python@v1 with: python-version: '3.6' architecture: 'x64' - name: set PIP_DOWNLOAD_CACHE shell: python run: | import os import platform from os.path import expanduser home = expanduser("~") cache_path = { "Linux": f"{home}/.cache/pip", "Darwin": f"{home}Library/Caches/pip", "Windows": f"{home}\\AppData\\Local\\pip\\Cache" }[platform.system()] os.system(f"echo PIP_DOWNLOAD_CACHE={cache_path} >> {os.environ['GITHUB_ENV']}") - uses: actions/cache@v2 with: path: ${{ env.PIP_DOWNLOAD_CACHE }} key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} restore-keys: ${{ runner.os }}-pip- - uses: actions/cache@v2 with: path: ~/.cache/xml2rfc key: xml2rfc restore-key: xml2rfc - if: matrix.os == 'macos-latest' run: brew install libmagic - if: matrix.os == 'windows-latest' run: pip install python-magic-bin - run: pip install xml2rfc - run: bundle exec rake