Skip to content

Add support for easyp.gen.yaml files. #79

@rustwizard

Description

@rustwizard

Could you add support for such config files? easyp.gen.yaml is a configuration file used by the easyp generate command to generate integration code. e.x. we have such project structure:

.
|── easyp.gen.ipam.yaml
|── easyp.gen.vm.yaml
|── easyp.yaml
|── proto
│   └── ipam
│           └── ipam.proto
│   └── vm
│           └── vm.proto
|── pkg
    └── ipam
    └── vm

easyp.yaml coud contains:

version: v1
directories:
  - proto/vm
  - proto/ipam
lint:
  use:
    - COMMENT_ENUM
    - COMMENT_ONEOF
    - COMMENT_RPC
    - COMMENT_SERVICE
deps:
  - github.com/googleapis/googleapis
  - github.com/bufbuild/protovalidate

easyp.gen.ipam.yaml:

version: v1
plugins:
  - name: go
    out: pkg/ipam
    opt: paths=source_relative

  - name: go-grpc
    out: pkg/ipam
    opt: paths=source_relative

easyp.gen.vm.yaml:

version: v1
plugins:
  - name: go
    out: pkg/vm
    opt: paths=source_relative

  - name: go-grpc
    out: pkg/vm
    opt: paths=source_relative

so then easyp generate --template easyp.gen.ipam.yaml proto/ipam should generate code into into pkg/ipam and
easyp generate --template easyp.gen.vm.yaml proto/vm into pkg/vm directories accordingly description in easyp.gen.* config files.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions