Skip to content

Commit

Permalink
bug: generate cb once #171
Browse files Browse the repository at this point in the history
  • Loading branch information
srinandan committed Feb 6, 2024
1 parent 59f823e commit 13fe9ef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cmd/integrations/scaffold.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ var ScaffoldCmd = &cobra.Command{
}
}

srcFolder := folder
baseFolder := folder
if env != "" {
folder = path.Join(folder, env)
if err = generateFolder(folder); err != nil {
Expand Down Expand Up @@ -107,7 +107,7 @@ var ScaffoldCmd = &cobra.Command{
}

clilog.Info.Printf("Storing the Integration: %s\n", name)
if err = generateFolder(path.Join(srcFolder, "src")); err != nil {
if err = generateFolder(path.Join(baseFolder, "src")); err != nil {
return err
}

Expand All @@ -117,7 +117,7 @@ var ScaffoldCmd = &cobra.Command{
}

if err = apiclient.WriteByteArrayToFile(
path.Join(srcFolder, "src", name+jsonExt),
path.Join(baseFolder, "src", name+jsonExt),
false,
integrationBody); err != nil {
return err
Expand Down Expand Up @@ -243,7 +243,7 @@ var ScaffoldCmd = &cobra.Command{
if cloudBuild {
clilog.Info.Printf("Storing cloudbuild.yaml\n")
if err = apiclient.WriteByteArrayToFile(
path.Join(folder, "cloudbuild.yaml"),
path.Join(baseFolder, "cloudbuild.yaml"),
false,
[]byte(utils.GetCloudBuildYaml())); err != nil {
return err
Expand Down

0 comments on commit 13fe9ef

Please sign in to comment.