Skip to content

Commit

Permalink
Add an optional description to Issue (#21)
Browse files Browse the repository at this point in the history
Since we can't put comments in JSON, this is the next best thing.
  • Loading branch information
ZacSweers committed Jun 21, 2023
1 parent 562d325 commit 0fb81cd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main/kotlin/slack/cli/exec/Issue.kt
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,18 @@ import com.squareup.moshi.JsonClass
* @property matchingText the matching text to look for in the log.
* @property groupingHash grouping hash for reporting to bugsnag. This should usually be unique, but
* can also be reused across issues that are part of the same general issue.
* @property retrySignal the [RetrySignal] to use when this issue is found.
* @property description an optional description of the issue. Not used in the CLI, just there for
* documentation in the config.
*/
@JsonClass(generateAdapter = true)
internal data class Issue(
val message: String,
@Json(name = "log_message") val logMessage: String,
@Json(name = "matching_text") val matchingText: String,
@Json(name = "grouping_hash") val groupingHash: String,
@Json(name = "retry_signal") val retrySignal: RetrySignal
@Json(name = "retry_signal") val retrySignal: RetrySignal,
val description: String? = null,
) {

private fun List<String>.checkContains(errorText: String): Boolean {
Expand Down

0 comments on commit 0fb81cd

Please sign in to comment.