Skip to content

Commit

Permalink
🔥 Kill Issues in activities in the cli (#1301)
Browse files Browse the repository at this point in the history
  • Loading branch information
Munklinde96 authored Oct 23, 2024
1 parent ae59c55 commit e3cbcf5
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 24 deletions.
20 changes: 0 additions & 20 deletions cmd/rig/cmd/activity/setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -185,26 +185,6 @@ func activityMessageToString(m *activity.Message) (string, string) {
}

return "Rollout", msg
case *activity.Message_Issue_:
var level string
switch v.Issue.GetLevel() {
case model.Level_LEVEL_INFORMATIVE:
level = "informatic"
case model.Level_LEVEL_MINOR:
level = "minor"
case model.Level_LEVEL_MAJOR:
level = "major"
case model.Level_LEVEL_CRITICAL:
level = "critical"
}

action := "reported"
if v.Issue.GetResolved() {
action = "resolved"
}

return "Issue", fmt.Sprintf("%s issue %s in rollout #%d: %s",
level, action, v.Issue.GetRolloutID(), v.Issue.GetMessage())

case *activity.Message_Project_:
action := "created"
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/api/platform-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -862,7 +862,6 @@ Different states a step can be in.
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| rollout | [Message.Rollout](#api-v1-activity-Message-Rollout) | | |
| issue | [Message.Issue](#api-v1-activity-Message-Issue) | | |
| project | [Message.Project](#api-v1-activity-Message-Project) | | |
| environment | [Message.Environment](#api-v1-activity-Message-Environment) | | |
| capsule | [Message.Capsule](#api-v1-activity-Message-Capsule) | | |
Expand Down Expand Up @@ -1171,6 +1170,7 @@ Scrypt hashing instance.
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| activities | [Activity](#api-v1-activity-Activity) | repeated | |
| total | [uint64](#uint64) | | |



Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ require (
github.com/nyaruka/phonenumbers v1.1.7
github.com/pkg/errors v0.9.1
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.70.0
github.com/rigdev/rig-go-api v0.0.0-20241022115326-03c0e30d80cc
github.com/rigdev/rig-go-api v0.0.0-20241023135935-eac99f7a930f
github.com/rigdev/rig-go-sdk v0.0.0-20241021090503-b515c1ca035f
github.com/rivo/tview v0.0.0-20240524063012-037df494fb76
github.com/robfig/cron v1.2.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -309,8 +309,8 @@ github.com/prometheus/common v0.59.1 h1:LXb1quJHWm1P6wq/U824uxYi4Sg0oGvNeUm1z5dJ
github.com/prometheus/common v0.59.1/go.mod h1:GpWM7dewqmVYcd7SmRaiWVe9SSqjf0UrwnYnpEZNuT0=
github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc=
github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk=
github.com/rigdev/rig-go-api v0.0.0-20241022115326-03c0e30d80cc h1:lWyePpmFgQT8UxAZtU17KaSPjLgbdi/J8MEntTLsgwQ=
github.com/rigdev/rig-go-api v0.0.0-20241022115326-03c0e30d80cc/go.mod h1:0yAwJnPID3gHfB3ETQAFYGM1tkNWkJKbVzauZiHmHKw=
github.com/rigdev/rig-go-api v0.0.0-20241023135935-eac99f7a930f h1:D87qhahpJla10fB/Ptd9/Ocg5ktGFJ3HosQDBrnn9vk=
github.com/rigdev/rig-go-api v0.0.0-20241023135935-eac99f7a930f/go.mod h1:0yAwJnPID3gHfB3ETQAFYGM1tkNWkJKbVzauZiHmHKw=
github.com/rigdev/rig-go-sdk v0.0.0-20241021090503-b515c1ca035f h1:SScDJVwFt/QzURstwUdi/ejnRoqB1ZsBLlICPD6Lt0c=
github.com/rigdev/rig-go-sdk v0.0.0-20241021090503-b515c1ca035f/go.mod h1:DJAwoPmFI6Jo71n/2VfFk/Nyzlyd24ARWCLC4Hsm1gg=
github.com/rivo/tview v0.0.0-20240524063012-037df494fb76 h1:iqvDlgyjmqleATtFbA7c14djmPh2n4mCYUv7JlD/ruA=
Expand Down

0 comments on commit e3cbcf5

Please sign in to comment.