Skip to content

Commit 78692c8

Browse files
detected new plugin versions
1 parent a309fbc commit 78692c8

71 files changed

Lines changed: 776 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
*
2+
!Dockerfile
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# syntax=docker/dockerfile:1.23
2+
FROM rust:1.95.0-alpine3.23@sha256:606fd313a0f49743ee2a7bd49a0914bab7deedb12791f3a846a34a4711db7ed2 AS builder
3+
RUN apk add --no-cache musl-dev
4+
WORKDIR /app
5+
ENV CARGO_REGISTRIES_CRATES_IO_PROTOCOL=sparse
6+
# The protoc-gen-connect-rust binary is a [[bin]] target in the
7+
# connectrpc-codegen crate. cargo install compiles it by crate name.
8+
RUN --mount=type=cache,target=/usr/local/cargo/registry,sharing=locked --mount=type=cache,target=/root/target \
9+
cargo install connectrpc-codegen --version 0.6.0 --locked --root /app
10+
11+
FROM gcr.io/distroless/static-debian13:latest@sha256:3592aa8171c77482f62bbc4164e6a2d141c6122554ace66e5cc910cadb961ff0 AS base
12+
13+
FROM scratch
14+
COPY --link --from=base / /
15+
COPY --link --from=builder /app/bin/protoc-gen-connect-rust /protoc-gen-connect-rust
16+
USER nobody
17+
ENTRYPOINT ["/protoc-gen-connect-rust"]
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
version: v1
2+
name: buf.build/anthropics/connect-rust
3+
plugin_version: v0.6.0
4+
source_url: https://github.com/anthropics/connect-rust
5+
description: Generates ConnectRPC service traits, typed clients, and monomorphic dispatchers for Rust. Compatible with the Connect, gRPC, and gRPC-Web protocols. Passes the full ConnectRPC conformance suite.
6+
deps:
7+
- plugin: buf.build/anthropics/buffa:v0.6.0
8+
output_languages:
9+
- rust
10+
spdx_license_id: Apache-2.0
11+
license_url: https://github.com/anthropics/connect-rust/blob/v0.6.0/LICENSE
12+
registry:
13+
cargo:
14+
rust_version: "1.88"
15+
deps:
16+
# ConnectRPC runtime: Router, Context, ConnectError, client transports.
17+
# https://github.com/anthropics/connect-rust/blob/v0.6.0/connectrpc/Cargo.toml
18+
- name: "connectrpc"
19+
req: "0.6.0"
20+
default_features: true
21+
# Generated service stubs use buffa::Message, buffa::view::OwnedView,
22+
# buffa::bytes::Bytes directly. Message types live in the buffa SDK
23+
# crate (via the plugin dep above); this dep is for the runtime API.
24+
- name: "buffa"
25+
req: "0.6.0"
26+
default_features: true
27+
# Well-known types. Service stubs whose request/response types are
28+
# WKTs (e.g. google.longrunning.Operations) reference them as
29+
# `::buffa_types::google::protobuf::...`, mirroring buffa-codegen's
30+
# extern_path mapping for `.google.protobuf`. Must be a direct dep
31+
# so the `::buffa_types` path resolves in the generated crate.
32+
- name: "buffa-types"
33+
req: "0.6.0"
34+
default_features: true
35+
features:
36+
- json
37+
# Streaming method signatures use futures::Stream.
38+
- name: "futures"
39+
req: "0.3"
40+
default_features: true
41+
# Client transport bounds reference http_body::Body.
42+
- name: "http-body"
43+
req: "1"
44+
default_features: true
45+
# The plugin accepts `extern_path=.=<rust_path>` (or the shorthand
46+
# `buffa_module=<rust_path>`) to tell it where the buffa-generated message
47+
# types live. BSR should inject this based on the buffa dep's SDK crate
48+
# name, same as tonic receives extern_path for its prost dep. Leaving
49+
# it out here; please advise if an explicit entry is needed.
50+
opts:
51+
# Emit one `<dotted.package>.rs` per proto package, mirroring the
52+
# buffa plugin's `file_per_package=true` opt. Matches the
53+
# prost/tonic filename convention the BSR Rust SDK lib.rs
54+
# synthesis expects.
55+
- file_per_package
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*
2+
!BUILD
3+
!cpp.cc
4+
!Dockerfile
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
cc_binary(
2+
name = "protoc-gen-cpp",
3+
srcs = ["cpp.cc"],
4+
deps = [
5+
"//:protoc_lib",
6+
],
7+
)
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# syntax=docker/dockerfile:1.23
2+
FROM debian:trixie-20260505@sha256:e2d08da6f42ef4b09b165d55528a12727aeed8240dc9edf888e3ec07e10ef9da AS build
3+
4+
ARG TARGETARCH
5+
ARG BAZEL_OPTS="--host_jvm_args=-Djava.net.preferIPv4Stack=true"
6+
7+
RUN apt-get update \
8+
&& apt-get install -y curl git cmake build-essential autoconf clang libc++-dev libtool pkg-config unzip zip
9+
RUN curl -fsSL -o /usr/local/bin/bazelisk https://github.com/bazelbuild/bazelisk/releases/download/v1.28.1/bazelisk-linux-${TARGETARCH} \
10+
&& chmod +x /usr/local/bin/bazelisk \
11+
&& mkdir /build \
12+
&& chown nobody:nogroup /build \
13+
&& usermod --home /build nobody
14+
15+
USER nobody
16+
WORKDIR /build
17+
RUN curl -fsSL -o protoc.tar.gz https://github.com/protocolbuffers/protobuf/releases/download/v35.0/protobuf-35.0.tar.gz \
18+
&& tar --strip-components=1 -zxf protoc.tar.gz \
19+
&& rm protoc.tar.gz
20+
RUN bazelisk ${BAZEL_OPTS} build '//:protoc_lib'
21+
COPY --link BUILD cpp.cc plugins/
22+
RUN bazelisk ${BAZEL_OPTS} build '//plugins:protoc-gen-cpp.stripped'
23+
24+
FROM gcr.io/distroless/cc-debian13:latest@sha256:8b5d1db6d2253036a53cb8362d3e3fa82a7caf84c247772c46a023166c64e977 AS base
25+
26+
FROM scratch
27+
COPY --from=base --link / /
28+
COPY --from=build --link --chmod=0755 /build/bazel-bin/plugins/protoc-gen-cpp .
29+
USER nobody
30+
ENTRYPOINT ["/protoc-gen-cpp"]
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
version: v1
2+
name: buf.build/protocolbuffers/cpp
3+
plugin_version: v35.0
4+
source_url: https://github.com/protocolbuffers/protobuf
5+
description: Base types for C++. Generates message and enum types.
6+
output_languages:
7+
- cpp
8+
spdx_license_id: BSD-3-Clause
9+
license_url: https://github.com/protocolbuffers/protobuf/blob/v35.0/LICENSE
10+
registry:
11+
cmake: {}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#include <google/protobuf/compiler/cpp/generator.h>
2+
#include <google/protobuf/compiler/plugin.h>
3+
4+
int main(int argc, char *argv[]) {
5+
google::protobuf::compiler::cpp::CppGenerator generator;
6+
return google::protobuf::compiler::PluginMain(argc, argv, &generator);
7+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
*
2+
!BUILD
3+
!csharp.cc
4+
!Dockerfile
5+
!build.csproj
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
cc_binary(
2+
name = "protoc-gen-csharp",
3+
srcs = ["csharp.cc"],
4+
deps = [
5+
"//:protoc_lib",
6+
],
7+
)

0 commit comments

Comments
 (0)