Skip to content

Commit

Permalink
fix helm name display and add stage id in qovery environment stage li…
Browse files Browse the repository at this point in the history
…st command
  • Loading branch information
acarranoqovery committed Feb 7, 2025
1 parent 79d460f commit 1f7ff05
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cmd/environment_stage_list.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@ package cmd
import (
"context"
"encoding/json"
"github.com/pterm/pterm"
"github.com/qovery/qovery-client-go"
"os"
"strconv"

"github.com/pterm/pterm"
"github.com/qovery/qovery-client-go"

"github.com/qovery/qovery-cli/utils"
"github.com/spf13/cobra"
)
Expand Down Expand Up @@ -49,6 +50,7 @@ var environmentStageListCmd = &cobra.Command{

for _, stage := range stages.GetResults() {
pterm.DefaultSection.WithBottomPadding(0).Println("deployment stage " + strconv.Itoa(int(stage.GetDeploymentOrder()+1)) + ": \"" + stage.GetName() + "\"")
pterm.Println("Stage id: " + stage.GetId())
if stage.GetDescription() != "" {
pterm.Println(stage.GetDescription())
}
Expand Down
6 changes: 6 additions & 0 deletions utils/qovery.go
Original file line number Diff line number Diff line change
Expand Up @@ -1415,6 +1415,12 @@ func GetServiceNameByIdAndType(client *qovery.APIClient, serviceId string, servi
return ""
}
return GetJobName(job)
case "HELM":
helm, _, err := client.HelmMainCallsAPI.GetHelm(context.Background(), serviceId).Execute()
if err != nil {
return ""
}
return helm.GetName()
default:
return "Unknown"
}
Expand Down

0 comments on commit 1f7ff05

Please sign in to comment.