diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/GoodMorningNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/GoodMorningNotify.java index 3f60ffd..3397eca 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/GoodMorningNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/GoodMorningNotify.java @@ -52,7 +52,7 @@ public class GoodMorningNotify extends Notify { .collect(Collectors.toList()) ).ifPresent(message::append); } else { - message.append("Поздравляю, у тебя ни одного ПР на проверку!").append(Smile.BR); + message.append("Поздравляю, у тебя ни одного ПР на проверку!"); } MessageUtils.pullRequestForNeedWork( pullRequestsNeedWork.stream() diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/AnswerCommentNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/AnswerCommentNotify.java index d60a0cc..aa08064 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/AnswerCommentNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/AnswerCommentNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.comment; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.domain.Answer; import org.sadtech.bot.vcs.core.domain.EntityType; @@ -14,7 +13,6 @@ import java.util.Set; import java.util.stream.Collectors; @Getter -@EqualsAndHashCode(callSuper = true) public class AnswerCommentNotify extends Notify { private final String youMessage; diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/CommentNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/CommentNotify.java index 99add74..e32465c 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/CommentNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/comment/CommentNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.comment; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.domain.EntityType; import org.sadtech.bot.vcs.core.domain.notify.Notify; @@ -11,7 +10,6 @@ import java.text.MessageFormat; import java.util.Set; @Getter -@EqualsAndHashCode(callSuper = true) public class CommentNotify extends Notify { private final String authorName; @@ -36,7 +34,7 @@ public class CommentNotify extends Notify { return MessageFormat.format( "{0} *Новое упоминание* | [ПР]({1}){2}" + "*{3}*: {4}", - Smile.BELL, url, Smile.HR, authorName, escapeMarkdown(message.replaceAll("@[\\w]+", "")) + Smile.BELL, url, Smile.HR, authorName, escapeMarkdown(message) ); } diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/NewPrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/NewPrNotify.java index b2ae276..ef754b1 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/NewPrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/NewPrNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.pullrequest; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.utils.Smile; @@ -9,7 +8,6 @@ import java.text.MessageFormat; import java.util.Set; @Getter -@EqualsAndHashCode(callSuper = true) public class NewPrNotify extends PrNotify { private final String description; diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/PrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/PrNotify.java index 273a102..f41d021 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/PrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/PrNotify.java @@ -1,6 +1,5 @@ package org.sadtech.bot.vcs.core.domain.notify.pullrequest; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.domain.EntityType; import org.sadtech.bot.vcs.core.domain.notify.Notify; @@ -8,7 +7,6 @@ import org.sadtech.bot.vcs.core.domain.notify.Notify; import java.util.Set; @Getter -@EqualsAndHashCode(callSuper = true) public abstract class PrNotify extends Notify { protected final String title; diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/ReviewersPrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/ReviewersPrNotify.java index 31932f4..2090b15 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/ReviewersPrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/ReviewersPrNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.pullrequest; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.domain.util.ReviewerChange; import org.sadtech.bot.vcs.core.utils.Smile; @@ -16,7 +15,6 @@ import static org.sadtech.bot.vcs.core.domain.util.ReviewerChange.Type.NEW; import static org.sadtech.bot.vcs.core.domain.util.ReviewerChange.Type.OLD; @Getter -@EqualsAndHashCode(callSuper = true) public class ReviewersPrNotify extends PrNotify { private final List reviewerChanges; diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/SmartPrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/SmartPrNotify.java index b562e4e..33d645b 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/SmartPrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/SmartPrNotify.java @@ -27,7 +27,7 @@ public class SmartPrNotify extends PrNotify { @Override public String generateMessage() { return MessageFormat.format( - "{0} *Напоминание о просмотре PullRequest*\n" + + "{0} *Напоминание о просмотре PullRequest*" + "{3}[{1}]({2})" + "{3}" + "{4} изменил свое решение на {5}\n\n", diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/StatusPrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/StatusPrNotify.java index 97e3115..b2bae05 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/StatusPrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/StatusPrNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.pullrequest; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.domain.PullRequestStatus; import org.sadtech.bot.vcs.core.utils.Smile; @@ -10,7 +9,6 @@ import java.text.MessageFormat; import java.util.Set; @Getter -@EqualsAndHashCode(callSuper = true) public class StatusPrNotify extends PrNotify { private final PullRequestStatus oldStatus; @@ -33,7 +31,7 @@ public class StatusPrNotify extends PrNotify { return MessageFormat.format( "{0} *Изменился статус вашего ПР*{1}" + "[{2}]({3}){1}" + - "{4}{5}{6}\n\n", + "{4} {5} {6}\n\n", Smile.PEN, Smile.HR, title, url, oldStatus.name(), Smile.ARROW, newStatus.name() ); } diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/UpdatePrNotify.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/UpdatePrNotify.java index 02fe4dc..8a3e8f2 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/UpdatePrNotify.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/domain/notify/pullrequest/UpdatePrNotify.java @@ -1,7 +1,6 @@ package org.sadtech.bot.vcs.core.domain.notify.pullrequest; import lombok.Builder; -import lombok.EqualsAndHashCode; import lombok.Getter; import org.sadtech.bot.vcs.core.utils.Smile; @@ -9,7 +8,6 @@ import java.text.MessageFormat; import java.util.Set; @Getter -@EqualsAndHashCode(callSuper = true) public class UpdatePrNotify extends PrNotify { private final String author; diff --git a/bot-core/src/main/java/org/sadtech/bot/vcs/core/scheduler/NotificationScheduler.java b/bot-core/src/main/java/org/sadtech/bot/vcs/core/scheduler/NotificationScheduler.java index 2d4f77f..d7c9cdb 100644 --- a/bot-core/src/main/java/org/sadtech/bot/vcs/core/scheduler/NotificationScheduler.java +++ b/bot-core/src/main/java/org/sadtech/bot/vcs/core/scheduler/NotificationScheduler.java @@ -74,7 +74,7 @@ public class NotificationScheduler { .map(Person::getLogin) .collect(Collectors.toSet()) ) - .message("☎️ Внимание созвон" + Smile.HR + "https://meet.google.com/czs-vigu-mte") + .message("☎️ Внимание созвон" + Smile.HR + "https://meet.google.com/avj-cdyy-enu") .build() );