Skip to content

feat: Add comprehensive Elixir language support#103

Merged
connerohnesorge merged 2 commits into
mainfrom
elixzer
Sep 17, 2025
Merged

feat: Add comprehensive Elixir language support#103
connerohnesorge merged 2 commits into
mainfrom
elixzer

Conversation

@connerohnesorge
Copy link
Copy Markdown
Owner

Summary

  • Implements full Elixir language support for Protocol Buffers and gRPC code generation
  • Adds working examples demonstrating both basic protobuf and gRPC service generation
  • Includes comprehensive documentation and integration tests

Implementation Details

Core Features

  • Protocol Buffer Messages: Full support for all protobuf types (enums, nested messages, maps, oneof)
  • gRPC Services: Complete service and stub generation with streaming RPC support
  • Namespace Support: Configurable module namespace prefixes for organized code
  • OTP Integration: Ready for supervision trees and Phoenix applications
  • Validation Hooks: Prepared infrastructure for future protovalidate support

Files Added/Modified

Language Implementation

  • src/languages/elixir/default.nix - Main Elixir language module
  • src/languages/elixir/grpc.nix - gRPC service generation sub-module
  • src/languages/elixir/validate.nix - Validation support hooks
  • src/lib/bufrnix-options.nix - Added Elixir configuration schema
  • src/lib/mkBufrnix.nix - Added protoc-gen-elixir package defaults

Examples

  • examples/elixir-basic/ - Basic protobuf message generation example
  • examples/elixir-grpc/ - Full gRPC service implementation example

Documentation

  • doc/src/content/docs/reference/languages/elixir.mdx - Comprehensive Elixir guide
  • doc/src/content/docs/reference/languages/elixir.x-basic-configuration.nix - Configuration example
  • doc/src/content/docs/reference/languages/index.mdx - Added Elixir to language index

Testing

  • test-examples.sh - Added elixir-basic and elixir-grpc to test suite

Test Plan

  • Basic example generates valid Elixir protobuf modules
  • gRPC example generates service and stub modules
  • Both examples build successfully with nix build
  • Code generation works with nix run
  • Examples added to test suite
  • Documentation builds correctly

Closes #96

🤖 Generated with Claude Code

Co-Authored-By: Claude noreply@anthropic.com

connerohnesorge and others added 2 commits September 13, 2025 14:56
- Add core Elixir language module with protobuf generation
- Implement gRPC service generation for Elixir
- Add validation hooks for future protovalidate support
- Create basic example demonstrating protobuf messages
- Create gRPC example with server and client implementations
- Add comprehensive documentation for Elixir integration
- Configure Elixir options in bufrnix-options.nix
- Add package defaults for protoc-gen-elixir

Implements #96

Co-Authored-By: Claude <noreply@anthropic.com>
- Add elixir-basic and elixir-grpc to test-examples.sh
- Tests verify generated .pb.ex files are created correctly

Co-Authored-By: Claude <noreply@anthropic.com>
@connerohnesorge connerohnesorge merged commit 5790f97 into main Sep 17, 2025
4 checks passed
@connerohnesorge connerohnesorge deleted the elixzer branch September 17, 2025 11:27
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.

Elixir Support

1 participant