Notify on run end only for runs marked Notify me
Auto runs no longer alert on failure or success; only notify_mode on does, unless the run_finished setting (now 'Notify when any run ends', default off) opts into every run end. Waiting still notifies auto and on runs. The setting is stored under a new key so a value saved under the old meaning is ignored.
This commit is contained in:
@@ -27,8 +27,9 @@ const (
|
||||
|
||||
// NotificationSettings is the typed form of the global notification choices.
|
||||
type NotificationSettings struct {
|
||||
// RunFinished notifies when a run with notify mode "auto" succeeds. Runs
|
||||
// started with notifications "on" always notify and "off" never do.
|
||||
// RunFinished makes every run end (success or failure) notify, not only
|
||||
// runs started with notify mode "on". Off by default: an "auto" run then
|
||||
// notifies only when it waits for a human decision, and "off" never does.
|
||||
RunFinished bool
|
||||
// ChatNeedsYou notifies when a chat asks a question or requests approval.
|
||||
ChatNeedsYou bool
|
||||
@@ -41,7 +42,7 @@ var NotificationSettingKeys = []string{NotifyRunFinished, NotifyChatNeedsYou, No
|
||||
|
||||
// DefaultNotificationSettings are the values before the operator changes any.
|
||||
func DefaultNotificationSettings() NotificationSettings {
|
||||
return NotificationSettings{RunFinished: true, ChatNeedsYou: true, ChatReplyFinished: false}
|
||||
return NotificationSettings{RunFinished: false, ChatNeedsYou: true, ChatReplyFinished: false}
|
||||
}
|
||||
|
||||
// Map returns the wire form with every key present.
|
||||
|
||||
Reference in New Issue
Block a user