Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BREAKING CHANGE: Move swift GRPC into its own package #119

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/go
{
"name": "Go",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/go:0-1.18",
"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {},
"ghcr.io/devcontainers/features/node:1": {},
"ghcr.io/devcontainers-contrib/features/typescript:2": {}
}

// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "go version",

// Configure tool-specific properties.
// "customizations": {},

// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
9 changes: 7 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,14 @@ let package = Package(
// Targets can depend on other targets in this package, and on products in packages this package depends on.
.target(
name: "XMTPProto",
dependencies: [.product(name: "SwiftProtobuf", package: "swift-protobuf"), .product(name: "GRPC", package: "grpc-swift")],
path: "swift"
dependencies: [.product(name: "SwiftProtobuf", package: "swift-protobuf")],
path: "swift/XMTPProto"
),
.target(
name: "XMTPProtoGRPC",
dependencies: [.product(name: "SwiftProtobuf", package: "swift-protobuf"), .product(name: "GRPC", package: "grpc-swift")],
path: "swift/XMTPProtoGRPC"
),
.testTarget(
name: "XMTPProtoTests",
dependencies: ["XMTPProto"],
Expand Down
4 changes: 2 additions & 2 deletions dev/swift/generate
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ docker run --rm -i -v${PWD}:/code xmtp/protoc-swift \
--proto_path=./proto \
--plugin=/usr/local/bin/protoc-gen-grpc-swift \
--grpc-swift_opt=Visibility=Public \
--grpc-swift_out=./swift \
--grpc-swift_out=./swift/XMTPProtoGRPC \
message_api/v1/message_api.proto

docker run --rm -i -v${PWD}:/code xmtp/protoc-swift \
--experimental_allow_proto3_optional \
--swift_out=./swift \
--swift_out=./swift/XMTPProto \
--swift_opt=Visibility=Public \
--proto_path=./proto \
keystore_api/v1/keystore.proto \
Expand Down
Loading
Loading