File tree Expand file tree Collapse file tree 2 files changed +29
-3
lines changed
Expand file tree Collapse file tree 2 files changed +29
-3
lines changed Original file line number Diff line number Diff line change @@ -58,11 +58,11 @@ jobs:
5858 with :
5959 name : nupkg
6060 - name : Prep packages
61- run : dotnet nuget add source --username BigMakCode --password ${{ secrets.DEPLOY_GITHUB_TOKEN }} --store-password-in-clear-text --name github "https://nuget.pkg.github.com/BigMakCode /index.json"
61+ run : dotnet nuget add source --username bvdcode --password ${{ secrets.DEPLOY_GITHUB_TOKEN }} --store-password-in-clear-text --name github "https://nuget.pkg.github.com/bvdcode /index.json"
6262 - name : Push package to GitHub packages
6363 if : needs.build.outputs.CommitsSinceVersionSource > 0 # Only release if there has been a commit/version change
6464 run : |
65- dotnet nuget push nupkg/*.nupkg --skip-duplicate --source "github"
65+ dotnet nuget push nupkg/*.nupkg --skip-duplicate --api-key ${{ secrets.DEPLOY_GITHUB_TOKEN }} -- source "github"
6666 dotnet nuget push nupkg/*.nupkg --skip-duplicate --api-key ${{ secrets.NUGET_KEY }} --source https://api.nuget.org/v3/index.json
6767
6868 # Create release
Original file line number Diff line number Diff line change @@ -67,6 +67,32 @@ info: TelegramBot.ConsoleTest.Controllers.HomeController[0]
6767
6868<p align =" right " ><a href =" #readme-top " >back to top</a ></p >
6969
70+ ## Features
71+
72+ * Dependency Injection - use ` Services ` property of ` BotBuilder ` to add services:
73+
74+ ``` CSharp
75+ builder .Services .AddDbContext <AppDbContext >(x => x .UseNpgsql (connectionString ));
76+ ```
77+
78+ * Send response to client - use ` BotControllerBase ` methods - ` Inline ` , ` Text ` , ` MarkDown ` :
79+
80+ ``` CSharp
81+ [BotCommand (" /start" )]
82+ public async Task < IActionResult > HandleStartAsync ()
83+ {
84+ string prompt = await _dbContext .Translations .GetTranslationAsync (" WelcomePrompt" , Language .English );
85+ InlineKeyboardMarkup keyboard = new KeyboardBuilder ()
86+ .WithColumns (2 )
87+ .AddButton (" 🇺🇸 English" , " /language/en" )
88+ .AddButton (" 🇷🇺 Русский" , " /language/ru" )
89+ .AddButton (" 🇪🇸 Español" , " /language/es" )
90+ .AddButton (" 🇺🇦 Українська" , " /language/uk" )
91+ .Build ();
92+ return Inline (prompt , keyboard );
93+ }
94+ ```
95+
7096## Roadmap
7197
7298- [x] Add command handlers
@@ -100,4 +126,4 @@ Distributed under the MIT License. See LICENSE.md for more information.
100126
101127# Contact
102128
103- [ E-Mail] ( mailto:github-telegram-bot-net@belov.us )
129+ [ E-Mail] ( mailto:github-telegram-bot-net@belov.us )
You can’t perform that action at this time.
0 commit comments