Files
ortools-clone/.github/workflows/amd64_linux_bazel.yml
dependabot[bot] ea0c49ed68 build(deps): bump actions/checkout in the github-actions group
Bumps the github-actions group with 1 update: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 4 to 5
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-12 01:42:55 +00:00

74 lines
2.1 KiB
YAML

# ref: https://github.com/actions/runner-images
name: amd64 Linux Bazel
on: [push, pull_request, workflow_dispatch]
concurrency:
group: ${{github.workflow}}-${{github.ref}}
cancel-in-progress: true
# Building using the github runner environement directly.
jobs:
native:
strategy:
matrix:
python: [
#{version: '3.10'},
#{version: '3.11'},
{version: '3.12'},
#{version: '3.13'},
]
fail-fast: false
name: amd64•Linux•Bazel•Python-${{matrix.python.version}}
runs-on: ubuntu-latest
env:
CC: gcc-12
CXX: g++-12
steps:
- uses: actions/checkout@v5
- name: Check Java
run: java -version
- name: Check mvn
run: mvn --version
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python.version}}
- name: Check Python
run: python --version
- name: Install Bazel
run: |
curl -fsSL https://bazel.build/bazel-release.pub.gpg | gpg --dearmor > bazel.gpg
sudo mv bazel.gpg /etc/apt/trusted.gpg.d/
echo "deb [arch=amd64] https://storage.googleapis.com/bazel-apt stable jdk1.8" | sudo tee /etc/apt/sources.list.d/bazel.list
sudo apt-get update
sudo apt-get install bazel
- name: Check Bazel
run: bazel version
- name: Change Python in .bazelrc
run: |
sed -i -e 's/\(python_version=\)3.[0-9]\+/\1${{matrix.python.version}}/g' .bazelrc
cat .bazelrc
- name: Change Python in .bazelrc
run: |
sed -i -e 's/\(DEFAULT_PYTHON =\) "3.[0-9]\+"/\1 "${{matrix.python.version}}"/g' MODULE.bazel
cat MODULE.bazel
- name: Build
run: >
bazel build
-c opt
--subcommands=pretty_print
//ortools/... //examples/...
- name: Test
run: >
bazel test
-c opt
--test_output=errors
//ortools/... //examples/...
amd64_linux_bazel:
runs-on: ubuntu-latest
needs: native
steps:
- uses: actions/checkout@v5