chore: init commit from GitHub
Some checks are pending
Deploy / update (push) Waiting to run
Build Project .NET / build (push) Waiting to run

This commit is contained in:
Lisoveliy
2025-05-12 19:44:33 +03:00
parent 11a3f40596
commit aebe654c38
107 changed files with 18953 additions and 403 deletions

View File

@@ -0,0 +1,20 @@
using System.Text;
using Telegram.Bot;
using Telegram.Bot.Types;
using Telegram.Bot.Types.Enums;
namespace TelegramBot.Commands.CommandMessages;
public class ChangelogCommandMessage : CommandMessage
{
public const string CommandName = "/changelog";
public override async Task InvokeFromMessage(ITelegramBotClient botClient, Update update, CancellationToken cancellationToken)
{
var text = new StringBuilder();
foreach (var log in Program.Config.Changelog)
{
text.Append($"Нововведения от <b>{log.Date}</b>:\n\n{log.Caption}\n\n");
}
await botClient.SendTextMessageAsync(update.Message?.Chat!, text.ToString(), cancellationToken: cancellationToken, parseMode: ParseMode.Html);
}
}