Skip to content

Commit

Permalink
Merge pull request #237 from depot/keep-output
Browse files Browse the repository at this point in the history
Only override the output format for non terminals when --output isn't specified
  • Loading branch information
kylegalbraith authored Dec 19, 2023
2 parents cd87be6 + 71afad6 commit 6d66bdd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/cmd/list/builds.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func NewCmdBuilds() *cobra.Command {
}

client := api.NewBuildClient()
if !helpers.IsTerminal() {
if !helpers.IsTerminal() && outputFormat == "" {
outputFormat = "csv"
}
if outputFormat != "" {
Expand Down
2 changes: 1 addition & 1 deletion pkg/cmd/list/projects.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func NewCmdProjects() *cobra.Command {
)

projectClient := api.NewProjectsClient()
if !helpers.IsTerminal() {
if !helpers.IsTerminal() && outputFormat == "" {
outputFormat = "csv"
}
if outputFormat != "" {
Expand Down

0 comments on commit 6d66bdd

Please sign in to comment.