fix: formatting and error message capitalization
- Run go fmt on modules/api/types.go to fix struct alignment - Use lowercase error messages to match codebase conventions 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -33,12 +33,12 @@ func RunActionJobs(ctx stdctx.Context, cmd *cli.Command) error {
|
|||||||
c.Ensure(context.CtxRequirement{RemoteRepo: true})
|
c.Ensure(context.CtxRequirement{RemoteRepo: true})
|
||||||
|
|
||||||
if cmd.Args().Len() < 1 {
|
if cmd.Args().Len() < 1 {
|
||||||
return fmt.Errorf("Run ID is required")
|
return fmt.Errorf("run ID is required")
|
||||||
}
|
}
|
||||||
|
|
||||||
runID, err := utils.ArgToIndex(cmd.Args().First())
|
runID, err := utils.ArgToIndex(cmd.Args().First())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("Invalid run ID: %w", err)
|
return fmt.Errorf("invalid run ID: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
client := api.NewClient(c.Login)
|
client := api.NewClient(c.Login)
|
||||||
|
|||||||
@@ -32,12 +32,12 @@ func RunActionLogs(ctx stdctx.Context, cmd *cli.Command) error {
|
|||||||
c.Ensure(context.CtxRequirement{RemoteRepo: true})
|
c.Ensure(context.CtxRequirement{RemoteRepo: true})
|
||||||
|
|
||||||
if cmd.Args().Len() < 1 {
|
if cmd.Args().Len() < 1 {
|
||||||
return fmt.Errorf("Job ID is required")
|
return fmt.Errorf("job ID is required")
|
||||||
}
|
}
|
||||||
|
|
||||||
jobID, err := utils.ArgToIndex(cmd.Args().First())
|
jobID, err := utils.ArgToIndex(cmd.Args().First())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("Invalid job ID: %w", err)
|
return fmt.Errorf("invalid job ID: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
client := api.NewClient(c.Login)
|
client := api.NewClient(c.Login)
|
||||||
|
|||||||
@@ -7,20 +7,20 @@ import "time"
|
|||||||
|
|
||||||
// ActionRun represents a workflow run
|
// ActionRun represents a workflow run
|
||||||
type ActionRun struct {
|
type ActionRun struct {
|
||||||
ID int64 `json:"id"`
|
ID int64 `json:"id"`
|
||||||
Title string `json:"display_title"`
|
Title string `json:"display_title"`
|
||||||
Path string `json:"path"`
|
Path string `json:"path"`
|
||||||
Status string `json:"status"`
|
Status string `json:"status"`
|
||||||
Conclusion string `json:"conclusion"`
|
Conclusion string `json:"conclusion"`
|
||||||
Event string `json:"event"`
|
Event string `json:"event"`
|
||||||
HeadBranch string `json:"head_branch"`
|
HeadBranch string `json:"head_branch"`
|
||||||
HeadSHA string `json:"head_sha"`
|
HeadSHA string `json:"head_sha"`
|
||||||
RunNumber int64 `json:"run_number"`
|
RunNumber int64 `json:"run_number"`
|
||||||
RunAttempt int64 `json:"run_attempt"`
|
RunAttempt int64 `json:"run_attempt"`
|
||||||
HTMLURL string `json:"html_url"`
|
HTMLURL string `json:"html_url"`
|
||||||
URL string `json:"url"`
|
URL string `json:"url"`
|
||||||
StartedAt *time.Time `json:"started_at"`
|
StartedAt *time.Time `json:"started_at"`
|
||||||
CompletedAt *time.Time `json:"completed_at"`
|
CompletedAt *time.Time `json:"completed_at"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ActionRunList is a list of workflow runs
|
// ActionRunList is a list of workflow runs
|
||||||
|
|||||||
Reference in New Issue
Block a user