Files
steampipe/connectionwatcher/config_map.go
kaidaguerre e0ff19a280 Update package naming to be consistent and follow Go standards. Closes #1282
General code spring cleaning:
* move file paths from `consts` package to `filepaths`
* move InitData and ExportData to query and control packages
2022-01-04 12:28:36 +00:00

19 lines
517 B
Go

package connectionwatcher
import (
pb "github.com/turbot/steampipe/pluginmanager/grpc/proto"
"github.com/turbot/steampipe/steampipeconfig/modconfig"
)
func NewConnectionConfigMap(connectionMap map[string]*modconfig.Connection) map[string]*pb.ConnectionConfig {
configMap := make(map[string]*pb.ConnectionConfig)
for k, v := range connectionMap {
configMap[k] = &pb.ConnectionConfig{
Plugin: v.Plugin,
PluginShortName: v.PluginShortName,
Config: v.Config,
}
}
return configMap
}