{"id":15323697,"url":"https://github.com/mvrilo/protoc-gen-d2","last_synced_at":"2025-04-19T16:20:22.929Z","repository":{"id":93057814,"uuid":"605123507","full_name":"mvrilo/protoc-gen-d2","owner":"mvrilo","description":"protoc-gen-d2 is a plugin for Google's Protocol Buffers (protoc) that generates svg of the entities specified in the proto files","archived":false,"fork":false,"pushed_at":"2023-02-27T14:54:14.000Z","size":235,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-06T17:04:06.882Z","etag":null,"topics":["diagram","go","golang","grpc","protobuf","protoc","protoc-gen","protocol-buffers","svg"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mvrilo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-22T13:52:45.000Z","updated_at":"2024-08-06T02:50:02.000Z","dependencies_parsed_at":"2024-02-06T03:15:40.553Z","dependency_job_id":null,"html_url":"https://github.com/mvrilo/protoc-gen-d2","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mvrilo%2Fprotoc-gen-d2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mvrilo%2Fprotoc-gen-d2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mvrilo%2Fprotoc-gen-d2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mvrilo%2Fprotoc-gen-d2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mvrilo","download_url":"https://codeload.github.com/mvrilo/protoc-gen-d2/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":220209158,"owners_count":16611668,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["diagram","go","golang","grpc","protobuf","protoc","protoc-gen","protocol-buffers","svg"],"created_at":"2024-10-01T09:21:06.401Z","updated_at":"2024-10-18T01:04:08.457Z","avatar_url":"https://github.com/mvrilo.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# protoc-gen-d2\n\n[![Go Report Card](https://goreportcard.com/badge/github.com/mvrilo/protoc-gen-d2)](https://goreportcard.com/report/github.com/mvrilo/protoc-gen-d2)\n\n`protoc-gen-d2` is a plugin for Google's Protocol Buffers (`protoc`) that generates svg of the entities specified in the `proto` files. The idea is to improve a project documentation with a visual representation of the data.\n\n## Example\n\nGiven a proto such as:\n\n```proto\nsyntax=\"proto3\";\n\npackage example;\n\nenum Status {\n    ACTIVE = 0;\n    INACTIVE = 1;\n}\n\nmessage Phone {\n    string number = 1;\n}\n\nmessage User {\n    string name = 1;\n    string email = 2;\n    Phone phone = 3;\n    Status status = 4;\n}\n\nmessage UserRequest {\n    string name = 1;\n}\n\nservice UserService {\n    rpc GetUser (UserRequest) returns (User);\n}\n```\n\nRun the `protoc` with `protoc-gen-d2`:\n\n```\nprotoc \\\n    -I ./testdata/proto \\\n    --plugin=protoc-gen-d2=./protoc-gen-d2 \\\n    --d2_out=\"testdata/generated/\" \\\n    ./testdata/proto/hello.proto\n```\n\nResult:\n\n[![example](testdata/generated/example.svg)](https://github.com/mvrilo/protoc-gen-d2/blob/master/testdata/generated/example.svg)\n\n## LICENSE\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmvrilo%2Fprotoc-gen-d2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmvrilo%2Fprotoc-gen-d2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmvrilo%2Fprotoc-gen-d2/lists"}