mirror of
https://github.com/TECHNOFAB11/powerproto.git
synced 2025-12-12 08:00:04 +01:00
feat: add tags feature
This commit is contained in:
parent
f394814c2e
commit
538ff9c6f6
6 changed files with 28 additions and 20 deletions
|
|
@ -26,7 +26,7 @@ import (
|
|||
// CompilerManager is to manage compiler
|
||||
type CompilerManager interface {
|
||||
// GetCompiler is used to get compiler of specified proto file path
|
||||
GetCompiler(ctx context.Context, protoFilePath string) (Compiler, error)
|
||||
GetCompiler(ctx context.Context, protoFilePath string, tags []string) (Compiler, error)
|
||||
}
|
||||
|
||||
// BasicCompilerManager is the basic implement of CompilerManager
|
||||
|
|
@ -66,8 +66,8 @@ func NewBasicCompilerManager(ctx context.Context,
|
|||
}
|
||||
|
||||
// GetCompiler is used to get compiler of specified proto file path
|
||||
func (b *BasicCompilerManager) GetCompiler(ctx context.Context, protoFilePath string) (Compiler, error) {
|
||||
config, err := b.configManager.GetConfig(ctx, protoFilePath)
|
||||
func (b *BasicCompilerManager) GetCompiler(ctx context.Context, protoFilePath string, tags []string) (Compiler, error) {
|
||||
config, err := b.configManager.GetConfig(ctx, protoFilePath, tags)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue