Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix(internal): fix googleapis-disco regen (#4354)
  • Loading branch information
noahdietz committed Jun 30, 2021
1 parent cfee361 commit aeea1ce
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions internal/gapicgen/generator/gapics.go
Expand Up @@ -491,7 +491,11 @@ func (g *GapicGenerator) manifest(confs []*microgenConfig) error {
entries[manual.DistributionName] = manual
}
for _, conf := range confs {
yamlPath := filepath.Join(g.googleapisDir, conf.apiServiceConfigPath)
dir := g.googleapisDir
if conf.googleapisDiscovery {
dir = g.googleapisDiscoDir
}
yamlPath := filepath.Join(dir, conf.apiServiceConfigPath)
yamlFile, err := os.Open(yamlPath)
if err != nil {
return err
Expand Down Expand Up @@ -535,7 +539,11 @@ func (g *GapicGenerator) copyMicrogenFiles() error {
func (g *GapicGenerator) parseAPIShortnames(confs []*microgenConfig, manualEntries []manifestEntry) (map[string]string, error) {
shortnames := map[string]string{}
for _, conf := range confs {
yamlPath := filepath.Join(g.googleapisDir, conf.apiServiceConfigPath)
dir := g.googleapisDir
if conf.googleapisDiscovery {
dir = g.googleapisDiscoDir
}
yamlPath := filepath.Join(dir, conf.apiServiceConfigPath)
yamlFile, err := os.Open(yamlPath)
if err != nil {
return nil, err
Expand Down

0 comments on commit aeea1ce

Please sign in to comment.