Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
95 commits
Select commit Hold shift + click to select a range
882ec64
bazel build //:gazelle-protobuf OK
pcj Jun 29, 2024
9b891e0
build(//:gazelle-protobuf) OK
pcj Jun 29, 2024
f8b2ba4
build(//:gazelle) OK
pcj Jun 29, 2024
0797bcf
bzlmod: wip on //example/place:place_scala_compile
pcj Jun 30, 2024
8204010
bb //example/thing:thing_scala_compile PASS
pcj Jul 1, 2024
4c4f9df
bt //pkg/... OK
pcj Jul 1, 2024
c96bac6
bb //example/thing:all OK
pcj Jul 1, 2024
a9a4d6f
bb //example/person:all OK
pcj Jul 1, 2024
d0bcc32
bb //example/... OK
pcj Jul 1, 2024
faf94ca
All examples building
pcj Jul 1, 2024
1488c51
Add proto_repository.apparent_name attr
pcj Jul 1, 2024
e4e8dbd
wip
pcj Jul 15, 2024
b08d20c
Merge branch 'master' into pcj/bzlmod
pcj Nov 25, 2024
1dded17
Support proto_compiled_sources with ts_project
pcj Aug 6, 2025
e722b99
github actions: upgrade setup-bazelisk to v3
pcj Aug 6, 2025
6f486ae
github actions: upgrade checkout to v4
pcj Aug 6, 2025
5907c0f
github actions: upgrade cache to v4
pcj Aug 6, 2025
7793ffc
Upgrade zlib to 1.3.1
pcj Aug 6, 2025
bc1474b
Remove grpc-gateway refs
pcj Aug 6, 2025
66d8b64
Fix test
pcj Aug 6, 2025
113e69f
Remove experimental C++ flags
pcj Aug 6, 2025
334227b
New strategy for depsgen in Makefile
pcj Aug 11, 2025
a173220
depsgen cleanup
pcj Aug 11, 2025
a90431d
Merge remote-tracking branch 'origin/master' into proto_compiled_sour…
pcj Aug 18, 2025
5832c98
ProtoCompileInfo: satisfy new provider requirement
pcj Aug 18, 2025
79f9eec
wip
pcj Aug 25, 2025
b3820c3
Merge branch 'proto_compiled_sources_revisited' into pcj/bzlmod-next
pcj Aug 25, 2025
44f3658
Upgrade bazel to 7.6.1
pcj Aug 25, 2025
a80cf3f
MODULE bazel re-organization
pcj Aug 25, 2025
5cf3fe1
Consolidate deps to bzlmod
pcj Aug 25, 2025
3c25074
bazel run @io_bazel_rules_go//go -- mod tidy -v
pcj Aug 25, 2025
f6faaca
bazel run @io_bazel_rules_go//go:go -- get github.com/bazelbuild/baze…
pcj Aug 25, 2025
8e417a3
go mod tidy
pcj Aug 25, 2025
619c836
bazel run gazelle
pcj Aug 25, 2025
b2a47a9
Remove depsgen tooling
pcj Aug 25, 2025
6f3fea7
Remove docs and closure refs (part 1)
pcj Aug 25, 2025
6eb866d
Remove closurejs rules
pcj Aug 25, 2025
39f3951
Remove nodejs rules
pcj Aug 25, 2025
2df76db
build //pkg/... OK
pcj Aug 25, 2025
f189da6
Remove closure and nodejs rule gen
pcj Aug 25, 2025
44fb867
bb //example/thing/... OK
pcj Aug 25, 2025
344a995
Mark failing targets as "manual"
pcj Aug 25, 2025
3b50d39
re-pin maven deps
pcj Aug 25, 2025
b77f008
Fix :routeguide_grpc_scala_library
pcj Aug 25, 2025
91c0fc7
Fix scala runtime version mismatch
pcj Aug 25, 2025
869326e
Fix scala golden test load import sorting
pcj Aug 25, 2025
c309d83
Fix golden test load import sorting
pcj Aug 25, 2025
1d82f71
dangerously fix failing scala golden test
pcj Aug 25, 2025
f7815d0
Convert example go bazel tests for MODULE.bazel
pcj Aug 25, 2025
0c0d58c
Mark failing tests as manual or skipped
pcj Aug 25, 2025
6bf549e
Restore missing http_archive / http_file
pcj Aug 25, 2025
bfa98dd
Update ci.yaml for better build coverage
pcj Aug 25, 2025
ec29f44
Add assets example
pcj Aug 25, 2025
34e75a1
Remove go_deps.bzl
pcj Aug 25, 2025
f98550a
Migrate to setup-bazel
pcj Aug 26, 2025
06b4baa
Restore protoc-gen-grpc-web versions
pcj Aug 26, 2025
22c91a6
Update cmd/gazelle OK
pcj Aug 26, 2025
c2e4c64
vendor files
pcj Aug 26, 2025
0006916
test cleanup
pcj Aug 26, 2025
b854045
Update README for cmd/gazelle
pcj Aug 26, 2025
ecb451e
Update go deps to latest
pcj Aug 26, 2025
4bd065d
vendor tools
pcj Aug 26, 2025
e5c13d1
Mark gazelle_test as manual
pcj Aug 26, 2025
9b897f2
Fix missing file ref
pcj Aug 26, 2025
d052e7d
Disambuguate @maven//...
pcj Aug 26, 2025
8f5db40
Fix protobuf_javascript
pcj Aug 26, 2025
fbdd725
Add gomodules language
pcj Aug 26, 2025
866c5ad
checkpoint: bazel-aquery-differ example proto_repository working
pcj Aug 28, 2025
a1180ae
checkpoint: go_modules copy rule sort of works
pcj Sep 5, 2025
6b84625
checkpoint: go_modules looking good, pre-cleanup
pcj Sep 6, 2025
4de0d28
checkpoint: happy with this
pcj Sep 6, 2025
a60c940
checkpoint: proto_go_modules
pcj Sep 6, 2025
86031b5
use generate for proto_repository_srcs (for now)
pcj Sep 8, 2025
64945c9
set bash explicitly
pcj Sep 8, 2025
692d441
fix example/toolchain/prebuilt go_bazel_test
pcj Sep 8, 2025
7a8243c
fix: remove obsolete go_bazel_test
pcj Sep 8, 2025
cfcb236
fix gencopy_test
pcj Sep 8, 2025
68bbc97
fix //cmd/gazelle:gazelle_test
pcj Sep 8, 2025
5062b7a
remove seemingly unnecessary manual build tag
pcj Sep 8, 2025
445a230
go_example_testdata cleanup phase 1
pcj Sep 8, 2025
f9ea1ec
fix gazelle_testdata_example phase 2
pcj Sep 8, 2025
7b1c27b
update proto_repository_tools_srcs
pcj Sep 8, 2025
7dbbb23
regen tools srcs
pcj Sep 8, 2025
2fb7f98
working on proto_repository example test
pcj Sep 8, 2025
7995d3d
fix proto_repository in default workspace
pcj Sep 8, 2025
701cdb7
final tidy step
pcj Sep 8, 2025
66f16c1
update proto_go_modules available imports
pcj Sep 8, 2025
5e35cf3
begin bcr publish pipeline
pcj Sep 8, 2025
d82b72d
break out golden example tests as manual for CI
pcj Sep 9, 2025
caf311c
tag all golden tests
pcj Sep 9, 2025
fd7ba37
skip manual tests for now
pcj Sep 9, 2025
37d073c
syntax: prefer any
pcj Sep 9, 2025
f97bb65
Implement language.LifecycleManager
pcj Sep 9, 2025
1547ddb
re-enable langs
pcj Sep 9, 2025
dd95bca
rename directive slightly
pcj Sep 9, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 2 additions & 5 deletions .bazelci/presubmit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ tasks:
default_workspace_ubuntu1804:
platform: ubuntu1804
build_targets:
- "@protoapis//..."
- "@protobufapis//..."
- "@googleapis//..."
test_targets:
- //example/...
Expand All @@ -19,11 +19,10 @@ tasks:
- -//pkg/plugin/grpc/grpc:grpc_test # TODO(pcj): error "bazel_testing: read-only filesystem"
test_flags:
- --config=bazelci
- --deleted_packages=//plugin/grpc-ecosystem/grpc-gateway
default_workspace_macos:
platform: macos
build_targets:
- "@protoapis//..."
- "@protobufapis//..."
- "@googleapis//..."
test_targets:
- //example/...
Expand All @@ -32,5 +31,3 @@ tasks:
- //plugin/...
- //rules/...
- //toolchain/...
test_flags:
- --deleted_packages=//plugin/grpc-ecosystem/grpc-gateway
1 change: 0 additions & 1 deletion .bazelignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
docs/
node_modules
plugin/bufbuild/node_modules
plugin/stephenh/ts-proto/node_modules
Expand Down
44 changes: 21 additions & 23 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -1,29 +1,27 @@
# =========================================================================
# STARTUP
# =========================================================================

common --jvmopt=-Djava.security.manager=allow
build --java_language_version=17
build --java_runtime_version=remotejdk_17
build --tool_java_language_version=17
build --tool_java_runtime_version=remotejdk_17
# Use blake3 as digest function instead of the much slower default sha256.
startup --digest_function=blake3

common --enable_platform_specific_config
build:windows --cxxopt='/std:c++14'
build:windows --host_cxxopt='/std:c++14'
build:linux --cxxopt='-std=c++14'
build:linux --host_cxxopt='-std=c++14'
build:macos --cxxopt='-std=c++14'
build:macos --host_cxxopt='-std=c++14'
build:freebsd --cxxopt='-std=c++14'
build:freebsd --host_cxxopt='-std=c++14'
# =========================================================================
# COMMON
# =========================================================================

build:bazelci --deleted_packages=docs
# Use '+' instead of the legacy '~' when resolving repo names.
common --incompatible_use_plus_in_repo_names

# workaround for scala
build --incompatible_java_common_parameters=false
# =========================================================================
# BUILD
# =========================================================================

# HOME appears to be required by //pkg/plugin/grpc/grpc:grpc_test
# (for github.com/bazelbuild/rules_go/go/tools/bazel_testing)
test --action_env=HOME
# Don't leak PATH and LD_LIBRARY_PATH into the build.
# build --incompatible_strict_action_env

# Don't depend on a JAVA_HOME pointing at a system JDK
# see https://github.com/bazelbuild/rules_jvm_external/issues/445
build --repo_env=JAVA_HOME=../bazel_tools/jdk
# Don't use legacy repository rules.
build --incompatible_disable_native_repo_rules

# C++17 for protobuf compatibility
build --host_cxxopt=-std=c++17
build --cxxopt=-std=c++17
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.4.0
7.6.1
7 changes: 3 additions & 4 deletions .github/workflows/ci.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# This file contains Bazel settings to apply on CI only.
# It is referenced with a --bazelrc option in the call to bazel in ci.yaml
# Debug where options came from
build --announce_rc

# Don't rely on test logs being easily accessible from the test runner,
# though it makes the log noisier.
test --test_output=errors

# This directory is configured in GitHub actions to be persisted between runs.
build --disk_cache=$HOME/.cache/bazel
build --repository_cache=$HOME/.cache/bazel-repo

# Allows tests to run bazelisk-in-bazel, since this is the cache folder used
test --test_env=XDG_CACHE_HOME
# Keep until @io_bazel_rules_scala is upgraded
build --incompatible_java_common_parameters=false
51 changes: 25 additions & 26 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,44 +11,43 @@ on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

concurrency:
# Cancel previous actions from the same PR: https://stackoverflow.com/a/72408109
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
test:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- uses: actions/checkout@v3

- uses: bazelbuild/setup-bazelisk@v2

- name: Mount bazel action cache
uses: actions/cache@v3
if: always()
with:
path: "~/.cache/bazel"
key: bazel
- uses: actions/checkout@v4

- name: Mount bazel repo cache
uses: actions/cache@v3
if: always()
- uses: bazel-contrib/[email protected]
with:
path: "~/.cache/bazel-repo"
key: bazel-repo
# Avoid downloading Bazel every time.
bazelisk-cache: true
# Store build cache per workflow.
disk-cache: true
# Share repository cache between workflows.
repository-cache: true
# Share external cache between workflows.
external-cache: true

- name: bazel build
run: >-
bazelisk
--bazelrc=.github/workflows/ci.bazelrc
--bazelrc=.bazelrc
build
...

- name: bazel test
env:
# Bazelisk will download bazel to here, ensure it is cached between runs.
XDG_CACHE_HOME: ~/.cache/bazel-repo
run: >-
bazel
bazelisk
--bazelrc=.github/workflows/ci.bazelrc
--bazelrc=.bazelrc
test
--deleted_packages=//plugin/grpc-ecosystem/grpc-gateway
//example/...
//pkg/...
//plugin/...
//language/...
//rules/...
//toolchain/...
...
44 changes: 0 additions & 44 deletions .github/workflows/format.yaml

This file was deleted.

35 changes: 35 additions & 0 deletions .github/workflows/publish-to-bcr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# See https://github.com/bazel-contrib/publish-to-bcr
name: Publish to BCR

on:
# Run the publish workflow after a successful release
# Can be triggered from the release.yaml workflow
workflow_call:
inputs:
tag_name:
required: true
type: string
secrets:
BCR_PUBLISH_TOKEN:
required: true
# In case of problems, let release engineers retry by manually dispatching
# the workflow from the GitHub UI
workflow_dispatch:
inputs:
tag_name:
description: 'Publish to BCR'
required: true
type: string

jobs:
publish:
uses: bazel-contrib/publish-to-bcr/.github/workflows/[email protected]
with:
draft: false
tag_name: ${{ inputs.tag_name }}
permissions:
attestations: write
contents: write
id-token: write
secrets:
publish_token: ${{ secrets.BCR_PUBLISH_TOKEN }}
49 changes: 24 additions & 25 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -1,31 +1,30 @@
# Cut a release whenever a new tag is pushed to the repo.
# Based on https://github.com/bazel-contrib/rules-template/blob/main/.github/workflows/release.yaml.
name: Release

on:
push:
tags:
- "v*.*.*"

# Allows owner to run this workflow manually from the Actions tab
- "*.*.*"
workflow_dispatch:

inputs:
tag_name:
description: git tag to release. The tag must exist.
required: true
type: string
jobs:
test:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Prepare workspace snippet
run: .github/workflows/workspace_snippet.sh ${{ env.GITHUB_REF_NAME }} > release_notes.txt

- name: Release
uses: softprops/action-gh-release@v1
with:
prerelease: false
# Use GH feature to populate the changelog automatically
generate_release_notes: true
body_path: release_notes.txt
release:
uses: bazel-contrib/.github/.github/workflows/[email protected]
with:
release_files: rules_proto-*.tar.gz
prerelease: true
tag_name: ${{ inputs.tag_name || github.ref_name }}
permissions:
attestations: write
contents: write
id-token: write
publish:
needs: release
uses: ./.github/workflows/publish-to-bcr.yaml
with:
tag_name: ${{ inputs.tag_name || github.ref_name }}
secrets:
publish_token: ${{ secrets.publish_token || secrets.BCR_PUBLISH_TOKEN }}
22 changes: 0 additions & 22 deletions .github/workflows/workspace_snippet.sh

This file was deleted.

2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/bazel-*
/.vscode
__pycache__
docs/vendor
node_modules
vendor/**/BUILD.bazel
/MODULE.bazel.lock
Loading
Loading