-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove bubbletea as a dependency
- Loading branch information
Showing
25 changed files
with
403 additions
and
382 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ permissions: | |
id-token: write | ||
|
||
env: | ||
GO_VERSION: '1.22.5' | ||
GO_VERSION: '1.23.0' | ||
|
||
jobs: | ||
release: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,7 @@ permissions: | |
contents: read | ||
|
||
env: | ||
GO_VERSION: '1.22.5' | ||
GO_VERSION: '1.23.0' | ||
|
||
jobs: | ||
vulncheck: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package cmd | ||
|
||
import ( | ||
"fmt" | ||
"sort" | ||
|
||
"github.com/dhth/act3/internal/gh" | ||
"github.com/dhth/act3/internal/types" | ||
"github.com/dhth/act3/internal/ui" | ||
) | ||
|
||
func render(workflows []types.Workflow, config types.Config) error { | ||
results := make([]gh.ResultData, len(workflows)) | ||
resultChannel := make(chan gh.ResultData) | ||
|
||
for _, wf := range workflows { | ||
go func(workflow types.Workflow) { | ||
resultChannel <- gh.GetWorkflowRuns(config.GHClient, workflow) | ||
}(wf) | ||
} | ||
|
||
for i := range workflows { | ||
r := <-resultChannel | ||
results[i] = r | ||
} | ||
|
||
sort.Slice(results, func(i, j int) bool { | ||
return results[i].Workflow.Name < results[j].Workflow.Name | ||
}) | ||
|
||
output, err := ui.GetOutput(config, results) | ||
if err != nil { | ||
return err | ||
} | ||
fmt.Print(output) | ||
return nil | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.