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

chore: add mutagen gRPC client #111

Merged
merged 4 commits into from
Mar 18, 2025
Merged

Conversation

ethanndickson
Copy link
Member

@ethanndickson ethanndickson commented Mar 13, 2025

Closes coder/internal#379

Much like in coder/coder-desktop-windows#48, this PR adds mutagen-proto.sh which finds all required files, following imports.

Right now, we use this client to stop the daemon over gRPC.

Copy link
Member Author

ethanndickson commented Mar 13, 2025

@ethanndickson ethanndickson marked this pull request as ready for review March 13, 2025 02:24
@ethanndickson ethanndickson force-pushed the ethan/mutagen-grpc-client branch from c7e529d to 008f582 Compare March 13, 2025 02:27
@ethanndickson ethanndickson self-assigned this Mar 13, 2025
mutagen_tag="$1"

# TODO: Change this to `coder/mutagen` once we add a version tag there
repo="mutagen-io/mutagen"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same deal as on the Windows repo, I'll make a follow-up once we have a tag.


# This script vendors the Mutagen proto files from a tag on a Mutagen GitHub repo.
# It is very similar to `Update-Proto.ps1` on `coder/coder-desktop-windows`.
# It's very unlikely that we'll use this script regularly.
Copy link
Member Author

@ethanndickson ethanndickson Mar 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In saying that, we could not commit any part of this SDK to the repo, and just generate them as part of make setup? I'm not sure which I'd prefer.

The Windows repo commits the .proto files (but the C# compiler can handle them at compile time), and we already commit .pb.swift files here for the VPN protocol.

@ethanndickson ethanndickson changed the base branch from ethan/replace-dir-spaces to graphite-base/111 March 13, 2025 02:54
@ethanndickson ethanndickson force-pushed the ethan/mutagen-grpc-client branch from 008f582 to b7a0a77 Compare March 13, 2025 02:54
@ethanndickson ethanndickson changed the base branch from graphite-base/111 to main March 13, 2025 02:55
@ethanndickson ethanndickson force-pushed the ethan/mutagen-grpc-client branch from b7a0a77 to 26c3593 Compare March 13, 2025 02:55
Copy link
Member

@deansheather deansheather left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's fine that you're committing them all to the repo. Your call on what to do though

Copy link
Member

@ThomasK33 ThomasK33 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Vendoring the protos is up to you.

Since one has to run make setup anyway to get an Xcode project, it's more of a question of personal preference whether you want it to be checked in or not.

@ethanndickson ethanndickson force-pushed the ethan/mutagen-grpc-client branch from 31aeac0 to 1f5dd2e Compare March 18, 2025 03:29
Copy link
Member Author

ethanndickson commented Mar 18, 2025

Merge activity

  • Mar 17, 11:40 PM EDT: A user started a stack merge that includes this pull request via Graphite.
  • Mar 17, 11:40 PM EDT: A user merged this pull request with Graphite.

@ethanndickson ethanndickson merged commit 0550ad1 into main Mar 18, 2025
4 checks passed
@ethanndickson ethanndickson deleted the ethan/mutagen-grpc-client branch March 18, 2025 03:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build a mutagen API client for coder-desktop-macos
3 participants