Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
xFile3160 committed Mar 16, 2024
2 parents a7dd881 + 9fcae82 commit d83c7c4
Show file tree
Hide file tree
Showing 1,355 changed files with 42,830 additions and 445 deletions.
1 change: 0 additions & 1 deletion .bazelrc

This file was deleted.

2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.4.0
7.0.2
22 changes: 22 additions & 0 deletions .github/workflows/dismiss_approvals.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Dismiss Stale PR Approvals
on:
pull_request_target:
types: [opened, synchronize, reopened]
branches:
- main

jobs:
dismiss_approvals:
runs-on: ubuntu-latest
steps:
- name: Harden Runner
uses: step-security/harden-runner@eb238b55efaa70779f274895e782ed17c84f2895 # v2.6.1
with:
egress-policy: audit

- name: Run BCR PR Reviewer
uses: bazelbuild/continuous-integration/actions/bcr-pr-reviewer@4b83ef1d08decb055ac7a6f864c3759fa22984a4 # master
with:
# This token needs to be updated annually on Feb 05.
token: ${{ secrets.BCR_PR_REVIEW_HELPER_TOKEN }}
action-type: dismiss_approvals
23 changes: 23 additions & 0 deletions .github/workflows/notify_maintainers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Notify Module Maintainers For PR Review
on:
pull_request_target:
branches:
- main
paths:
- 'modules/**'

jobs:
notify_maintainers:
runs-on: ubuntu-latest
steps:
- name: Harden Runner
uses: step-security/harden-runner@eb238b55efaa70779f274895e782ed17c84f2895 # v2.6.1
with:
egress-policy: audit

- name: Run BCR PR Reviewer
uses: bazelbuild/continuous-integration/actions/bcr-pr-reviewer@4b83ef1d08decb055ac7a6f864c3759fa22984a4 # master
with:
# This token needs to be updated annually on Feb 05.
token: ${{ secrets.BCR_PR_REVIEW_HELPER_TOKEN }}
action-type: notify_maintainers
23 changes: 23 additions & 0 deletions .github/workflows/review_prs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Review BCR Pull Requests
on:
schedule:
- cron: "*/10 * * * *" # Run this action every 10 mins
workflow_dispatch: # So that this can be triggered manually

jobs:
review_prs:
runs-on: ubuntu-latest
steps:
- name: Harden Runner
if: github.repository_owner == 'bazelbuild'
uses: step-security/harden-runner@eb238b55efaa70779f274895e782ed17c84f2895 # v2.6.1
with:
egress-policy: audit

- name: Run BCR PR Reviewer
if: github.repository_owner == 'bazelbuild'
uses: bazelbuild/continuous-integration/actions/bcr-pr-reviewer@4b83ef1d08decb055ac7a6f864c3759fa22984a4 # master
with:
# This token needs to be updated annually on Feb 05.
token: ${{ secrets.BCR_PR_REVIEW_HELPER_TOKEN }}
action-type: review_prs
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
tools/__pycache__
tools/node_modules
.vscode
/bazel-*
.vscode
MODULE.bazel.lock
2 changes: 1 addition & 1 deletion MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module(
)

bazel_dep(name = "aspect_rules_js", version = "1.34.1")
bazel_dep(name = "rules_python", version = "0.26.0")
bazel_dep(name = "rules_python", version = "0.27.1")

python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
Expand Down
9 changes: 8 additions & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,16 @@ To contribute a new module or a new version to an existing module, you can clone
```bash
git clone https://github.com/bazelbuild/bazel-central-registry.git
cd bazel-central-registry
python3 ./tools/add_module.py
bazel run //tools:add_module
```

The script will generate all require changes based on your input, please review, modify and commit the change, then send a PR to the BCR repository.

If you are the project owner, you can set up the [Publish to BCR](https://github.com/apps/publish-to-bcr) Github App for your repository to automatically send a PR to the BCR when cutting a new release.

When manually editing files you may find `bazel run -- //tools:update_integrity foomod` useful to update the integrity hashes in foomod's source.json file.
The tool also accepts a `--version` option to update the source.json of a specific version of the module (instead of latest).

## Presubmit

Every module version must pass the BCR presubmit before getting merged. The presubmit validates the correctness and consistency of module information, then runs build and test targets specified in the `presubmit.yml` file. The BCR presubmit is driven by the [bcr_presubmit.py](https://github.com/bazelbuild/continuous-integration/blob/master/buildkite/bazel-central-registry/bcr_presubmit.py) script on [Bazel CI](https://github.com/bazelbuild/continuous-integration/tree/master/buildkite#bazel-continuous-integration).
Expand Down Expand Up @@ -56,10 +59,12 @@ matrix:
- ubuntu2004
- macos
- windows
bazel: [6.x, 7.x]
tasks:
verify_targets:
name: Verify build targets
platform: ${{ platform }}
bazel: ${{ bazel }}
build_targets:
- '@zlib//:zlib'
```
Expand Down Expand Up @@ -94,10 +99,12 @@ bcr_test_module:
- ubuntu2004
- macos
- windows
bazel: [6.x, 7.x]
tasks:
run_test_module:
name: Run test module
platform: ${{ platform }}
bazel: ${{ bazel }}
build_targets:
- //java/src/com/github/rules_jvm_external/examples/bzlmod:bzlmod_example
```
Expand Down
3 changes: 2 additions & 1 deletion metadata.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"maintainers": {
"description": "Individuals who can be notified when the module requires human attention",
"type": "array",
"minItems": 1,
"items": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -46,5 +47,5 @@
}
},
"additionalProperties": false,
"required": ["homepage", "versions"]
"required": ["homepage", "versions", "maintainers"]
}
11 changes: 11 additions & 0 deletions modules/abseil-cpp/20230802.1/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
"""Module definition for Abseil LTS 20230802.1."""
module(
name = "abseil-cpp",
version = "20230802.1",
compatibility_level = 1,
)
bazel_dep(name = "rules_cc", version = "0.0.8")
bazel_dep(name = "platforms", version = "0.0.7")
bazel_dep(name = "bazel_skylib", version = "1.4.1")
bazel_dep(name = "googletest", version = "1.14.0", repo_name = "com_google_googletest")
bazel_dep(name = "google_benchmark", version = "1.8.2", repo_name = "com_github_google_benchmark", dev_dependency=True)
14 changes: 14 additions & 0 deletions modules/abseil-cpp/20230802.1/patches/module_dot_bazel.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
--- MODULE.bazel
+++ MODULE.bazel
@@ -0,0 +1,11 @@
+"""Module definition for Abseil LTS 20230802.1."""
+module(
+ name = "abseil-cpp",
+ version = "20230802.1",
+ compatibility_level = 1,
+)
+bazel_dep(name = "rules_cc", version = "0.0.8")
+bazel_dep(name = "platforms", version = "0.0.7")
+bazel_dep(name = "bazel_skylib", version = "1.4.1")
+bazel_dep(name = "googletest", version = "1.14.0", repo_name = "com_google_googletest")
+bazel_dep(name = "google_benchmark", version = "1.8.2", repo_name = "com_github_google_benchmark", dev_dependency=True)
16 changes: 16 additions & 0 deletions modules/abseil-cpp/20230802.1/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
matrix:
platform:
- centos7_java11_devtoolset10
- debian10
- ubuntu2004
- macos
- windows
tasks:
verify_targets:
name: Verify build targets
platform: ${{ platform }}
build_flags:
- '--cxxopt=-std=c++14'
build_targets:
- '@abseil-cpp//absl/strings'
- '@abseil-cpp//absl/flags:flag'
9 changes: 9 additions & 0 deletions modules/abseil-cpp/20230802.1/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"url": "https://github.com/abseil/abseil-cpp/archive/refs/tags/20230802.1.tar.gz",
"integrity": "sha256-mHzpjwLu+6+TDW44qxaqBXNyNNevurLVxOp62+UMKO0=",
"strip_prefix": "abseil-cpp-20230802.1",
"patch_strip": 0,
"patches": {
"module_dot_bazel.patch": "sha256-QRZ3pjptCi+f7kEUY9rJZYln4tTl6bZu11laagT0YDk="
}
}
39 changes: 39 additions & 0 deletions modules/abseil-cpp/20240116.0/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Copyright 2024 The Abseil Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# https://bazel.build/external/overview#bzlmod

module(
name = "abseil-cpp",
version = "20240116.0",
compatibility_level = 1,
)

# Only direct dependencies need to be listed below.
# Please keep the versions in sync with the versions in the WORKSPACE file.

bazel_dep(name = "bazel_skylib",
version = "1.5.0")

bazel_dep(name = "google_benchmark",
version = "1.8.3",
repo_name = "com_github_google_benchmark",
dev_dependency = True)

bazel_dep(name = "googletest",
version = "1.14.0.bcr.1",
repo_name = "com_google_googletest")

bazel_dep(name = "platforms",
version = "0.0.8")
16 changes: 16 additions & 0 deletions modules/abseil-cpp/20240116.0/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
matrix:
platform:
- centos7_java11_devtoolset10
- debian10
- ubuntu2004
- macos
- windows
tasks:
verify_targets:
name: Verify build targets
platform: ${{ platform }}
build_flags:
- '--cxxopt=-std=c++14'
build_targets:
- '@abseil-cpp//absl/strings'
- '@abseil-cpp//absl/flags:flag'
5 changes: 5 additions & 0 deletions modules/abseil-cpp/20240116.0/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"url": "https://github.com/abseil/abseil-cpp/releases/download/20240116.0/abseil-cpp-20240116.0.tar.gz",
"integrity": "sha256-M4QgRIsUDw39Gh6jw85xs7wXIHHyT02aV9WbRQN9pEA=",
"strip_prefix": "abseil-cpp-20240116.0"
}
39 changes: 39 additions & 0 deletions modules/abseil-cpp/20240116.1/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Copyright 2024 The Abseil Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# https://bazel.build/external/overview#bzlmod

module(
name = "abseil-cpp",
version = "20240116.1",
compatibility_level = 1,
)

# Only direct dependencies need to be listed below.
# Please keep the versions in sync with the versions in the WORKSPACE file.

bazel_dep(name = "bazel_skylib",
version = "1.5.0")

bazel_dep(name = "google_benchmark",
version = "1.8.3",
repo_name = "com_github_google_benchmark",
dev_dependency = True)

bazel_dep(name = "googletest",
version = "1.14.0.bcr.1",
repo_name = "com_google_googletest")

bazel_dep(name = "platforms",
version = "0.0.8")
11 changes: 11 additions & 0 deletions modules/abseil-cpp/20240116.1/patches/module_dot_bazel.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- MODULE.bazel
+++ MODULE.bazel
@@ -16,7 +16,7 @@

module(
name = "abseil-cpp",
- version = "20240116.0",
+ version = "20240116.1",
compatibility_level = 1,
)

20 changes: 20 additions & 0 deletions modules/abseil-cpp/20240116.1/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
matrix:
bazel:
- 6.x
- 7.x
platform:
- centos7_java11_devtoolset10
- debian10
- ubuntu2004
- macos
- windows
tasks:
verify_targets:
name: Verify build targets
platform: ${{ platform }}
bazel: ${{ bazel }}
build_flags:
- '--cxxopt=-std=c++14'
build_targets:
- '@abseil-cpp//absl/strings'
- '@abseil-cpp//absl/flags:flag'
9 changes: 9 additions & 0 deletions modules/abseil-cpp/20240116.1/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"url": "https://github.com/abseil/abseil-cpp/releases/download/20240116.1/abseil-cpp-20240116.1.tar.gz",
"integrity": "sha256-PHQyBN94NmrS6vI21mMdg/a8ko0XBd0AALhy5Ttz3Go=",
"strip_prefix": "abseil-cpp-20240116.1",
"patch_strip": 0,
"patches": {
"module_dot_bazel.patch": "sha256-H6J0U5xTQRVVGFkTsBioOCeWetuCfpavigN8YvpQkIQ="
}
}
13 changes: 11 additions & 2 deletions modules/abseil-cpp/metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
{
"homepage": "https://github.com/abseil/abseil-cpp",
"maintainers": [],
"maintainers": [
{
"email": "[email protected]",
"github": "derekmauro",
"name": "Derek Mauro"
}
],
"repository": [
"github:abseil/abseil-cpp"
],
Expand All @@ -10,7 +16,10 @@
"20220623.1",
"20230125.1",
"20230802.0",
"20230802.0.bcr.1"
"20230802.0.bcr.1",
"20230802.1",
"20240116.0",
"20240116.1"
],
"yanked_versions": {}
}
Loading

0 comments on commit d83c7c4

Please sign in to comment.