Skip to content

Commit a2ca791

Browse files
authored
Allow to run bazel with just //... (#4963)
1 parent c0b7d13 commit a2ca791

File tree

15 files changed

+28
-28
lines changed

15 files changed

+28
-28
lines changed

.github/workflows/amd64_linux_bazel.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,9 @@ jobs:
6969
key: ${{env.cache-name}}
7070
path: ${{env.cache-root}}
7171
- name: Build
72-
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //ortools/... //examples/...
72+
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //...
7373
- name: Test
74-
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //ortools/... //examples/...
74+
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //...
7575
- name: Save Bazel cache for branch main even when Build and Test fail.
7676
uses: actions/cache/save@v4
7777
# https://docs.github.com/en/actions/reference/workflows-and-actions/dependency-caching#restrictions-for-accessing-a-cache

.github/workflows/amd64_macos_bazel.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,9 @@ jobs:
6363
key: ${{env.cache-name}}
6464
path: ${{env.cache-root}}
6565
- name: Build
66-
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //ortools/... //examples/...
66+
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //...
6767
- name: Test
68-
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //ortools/... //examples/...
68+
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //...
6969
- name: Save Bazel cache for branch main even when Build and Test fail.
7070
uses: actions/cache/save@v4
7171
# https://docs.github.com/en/actions/reference/workflows-and-actions/dependency-caching#restrictions-for-accessing-a-cache

.github/workflows/amd64_windows_bazel.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ jobs:
5858
key: ${{env.cache-name}}
5959
path: ${{env.cache-root}}
6060
- name: Build
61-
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //ortools/... //examples/...
61+
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //...
6262
- name: Test
63-
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //ortools/... //examples/...
63+
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //...
6464
- name: Save Bazel cache for branch main even when Build and Test fail.
6565
uses: actions/cache/save@v4
6666
# https://docs.github.com/en/actions/reference/workflows-and-actions/dependency-caching#restrictions-for-accessing-a-cache

.github/workflows/arm64_macos_bazel.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,9 @@ jobs:
6363
key: ${{env.cache-name}}
6464
path: ${{env.cache-root}}
6565
- name: Build
66-
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //ortools/... //examples/...
66+
run: bazel --output_user_root=${{env.cache-root}} build --config=ci //...
6767
- name: Test
68-
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //ortools/... //examples/...
68+
run: bazel --output_user_root=${{env.cache-root}} test --config=ci //...
6969
- name: Save Bazel cache for branch main even when Build and Test fail.
7070
uses: actions/cache/save@v4
7171
# https://docs.github.com/en/actions/reference/workflows-and-actions/dependency-caching#restrictions-for-accessing-a-cache

bazel/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,13 @@ OR-Tools depends on several mandatory libraries.
7373
## Compilation
7474

7575
```sh
76-
bazel build -c opt //ortools/... //examples/...
76+
bazel build -c opt //...
7777
```
7878

7979
## Testing
8080

8181
```sh
82-
bazel test -c opt //ortools/... //examples/...
82+
bazel test -c opt //...
8383
```
8484

8585
## Integration

bazel/docker/almalinux/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ COPY . .
3636

3737
FROM devel AS build
3838
RUN bazel version
39-
RUN bazel build --config=ci //ortools/... //examples/...
39+
RUN bazel build --config=ci //...
4040

4141
FROM build AS test
42-
RUN bazel test --config=ci //ortools/... //examples/...
42+
RUN bazel test --config=ci //...

bazel/docker/alpine/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ COPY . .
2424

2525
FROM devel AS build
2626
RUN bazel version
27-
RUN bazel build --config=ci //ortools/... //examples/...
27+
RUN bazel build --config=ci //...
2828

2929
FROM build AS test
30-
RUN bazel test --config=ci //ortools/... //examples/...
30+
RUN bazel test --config=ci //...

bazel/docker/archlinux/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ COPY . .
1616

1717
FROM devel AS build
1818
RUN bazel version
19-
RUN bazel build --config=ci //ortools/... //examples/...
19+
RUN bazel build --config=ci //...
2020

2121
FROM build AS test
22-
RUN bazel test --config=ci //ortools/... //examples/...
22+
RUN bazel test --config=ci //...

bazel/docker/debian/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ COPY . .
2323

2424
FROM devel AS build
2525
RUN bazel version
26-
RUN bazel build --config=ci //ortools/... //examples/...
26+
RUN bazel build --config=ci //...
2727

2828
FROM build AS test
29-
RUN bazel test --config=ci //ortools/... //examples/...
29+
RUN bazel test --config=ci //...

bazel/docker/fedora/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ COPY . .
3636

3737
FROM devel AS build
3838
RUN bazel version
39-
RUN bazel build --config=ci //ortools/... //examples/...
39+
RUN bazel build --config=ci //...
4040

4141
FROM build AS test
42-
RUN bazel test --config=ci //ortools/... //examples/...
42+
RUN bazel test --config=ci //...

0 commit comments

Comments
 (0)