Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .coderabbit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
language: "en"
early_access: false
reviews:
profile: "chill"
request_changes_workflow: false
high_level_summary: true
poem: false
review_status: true
collapse_walkthrough: false
auto_review:
enabled: true
drafts: false
path_filters:
- "!**/*.min.js"
- "!**/bin/**"
- "!**/obj/**"
- "!**/TestResults/**"
- "!**/*.Designer.cs"
chat:
auto_reply: true
4 changes: 2 additions & 2 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Setup .NET
uses: actions/setup-dotnet@v3
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
dotnet-version: 10.0.x

- name: Run Unit Tests
run: |
Expand Down
25 changes: 11 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,40 +1,37 @@
# NosCoreBot #

<p align="center">
<img src="https://cdn.discordapp.com/attachments/319565884454731795/426892646288457728/N2.png"/>
<img width="250px" src="https://github.com/NosCoreIO/NosCore.Packets/blob/15.0.1/icon.png"/>
</p>

# NosCoreBot #
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/5601a6d1e4224338b142c76bdeb8f9eb)](https://app.codacy.com/app/NosCoreIO/NosCoreBot?utm_source=github.com&utm_medium=referral&utm_content=NosCoreIO/NosCoreBot&utm_campaign=Badge_Grade_Settings)
[![.NET](https://github.com/NosCoreIO/NosCoreBot/actions/workflows/dotnet.yml/badge.svg?branch=master)](https://github.com/NosCoreIO/NosCoreBot/actions/workflows/dotnet.yml)

# Special Thanks for Contributions #
<p align="left">
<a href="https://aws.amazon.com"><img height="100px" src="https://chiefit.me/wp-content/uploads/2019/06/Amazon-Web-Services_logo835x396.png"/></a>
<a href="https://www.navicat.com"><img height="100px" src="https://i.ibb.co/kx9WJgv/Navicat-Premium.png"/></a>
<a href="https://www.jetbrains.com"><img height="100px" src="https://upload.wikimedia.org/wikipedia/commons/thumb/1/1a/JetBrains_Logo_2016.svg/1200px-JetBrains_Logo_2016.svg.png"/></a>
<a href="https://www.navicat.com"><img height="100px" src="https://user-images.githubusercontent.com/35202750/207230064-dcf23adc-9e96-4481-9a53-cd212f5bd60e.png"/></a>
</p>

## You want to contribute ? ##
[![Discord](https://i.gyazo.com/2115a3ecb258220f5b1a8ebd8c50eb8f.png)](https://discord.gg/Eu3ETSw)

## You like our work ? ##
<a href='https://github.com/sponsors/0Lucifer0' target='_blank'><img height='48' style='border:0px;height:46px;' src='https://i.gyazo.com/47b2ca2eb6e1ce38d02b04c410e1c82a.png' border='0' alt='Sponsor me!' /></a>
<a href='https://ko-fi.com/A3562BQV' target='_blank'><img height='46' style='border:0px;height:46px;' src='https://az743702.vo.msecnd.net/cdn/kofi3.png?v=0' border='0' alt='Buy Me a Coffee at ko-fi.com' /></a> <a href='https://www.patreon.com/bePatron?u=6503887' target='_blank'><img height='46' style='border:0px;height:46px;' src='https://c5.patreon.com/external/logo/become_a_patron_button@2x.png' border='0' alt='Become a Patron!' /></a>
<a href='https://ko-fi.com/A3562BQV' target='_blank'><img height='46' style='border:0px;height:46px;' src='https://az743702.vo.msecnd.net/cdn/kofi3.png?v=0' border='0' alt='Buy Me a Coffee at ko-fi.com' /></a>
<a href='https://www.patreon.com/bePatron?u=6503887' target='_blank'><img height='46' style='border:0px;height:46px;' src='https://c5.patreon.com/external/logo/become_a_patron_button@2x.png' border='0' alt='Become a Patron!' /></a>

## Achtung! ##
## Warning! ##
We are not responsible of any damages caused by bad usage of our source. Please before asking questions or installing this source read this readme and also do a research, google is your friend. If you mess up when installing our source because you didnt follow it, we will laugh at you. A lot.

## Instructions to contribute ##

### Disclaimer ###
This project not for commercial use.

## Disclaimer ##
This project is a community project not for commercial use. The result is to learn and program together for prove the study.
This project is a community project not for commercial use. The result is to learn and program together for prove the study.

## Legal ##
### Legal ###
This is an independent and unofficial server for educational use ONLY. Using the Project might be against the TOS.

### Contribution is only possible with Visual Studio 2017 ###
We recommend usage of :
### Contribution is only possible with Visual Studio 2026 ###
We recommend usage of :
* [Roslynator extension](https://github.com/JosefPihrt/Roslynator).
* [Resharper](https://www.jetbrains.com/resharper/)
8 changes: 4 additions & 4 deletions src/NosCoreBot/NosCoreBot.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
Expand All @@ -14,9 +14,9 @@
<PackageReference Include="ConsoleTableExt" Version="3.2.0" />
<PackageReference Include="Discord.Net" Version="3.13.0" />
<PackageReference Include="Humanizer.Core" Version="2.14.1" />
<PackageReference Include="Microsoft.AspNetCore.Hosting.WindowsServices" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Hosting.WindowsServices" Version="8.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Hosting.WindowsServices" Version="10.0.3" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="10.0.3" />
<PackageReference Include="Microsoft.Extensions.Hosting.WindowsServices" Version="10.0.3" />
<PackageReference Include="NosCore.ParserInputGenerator" Version="3.0.0" />
<PackageReference Include="NosCore.Shared" Version="5.0.0" />
</ItemGroup>
Expand Down
39 changes: 0 additions & 39 deletions src/NosCoreBot/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,43 +44,4 @@ public static IHostBuilder CreateHostBuilder(string[] args)

}
}

public class Worker : BackgroundService
{
private readonly DiscordSocketClient _client;
private readonly CommandService _cmservice;
private readonly CommandHandlingService _chservice;
private readonly TimeHandlingService _thservice;

public Worker(DiscordSocketClient client, CommandService cmservice, CommandHandlingService chservice,
TimeHandlingService thservice)
{
_client = client;
_cmservice = cmservice;
_chservice = chservice;
_thservice = thservice;
}

protected override async Task ExecuteAsync(CancellationToken stoppingToken)
{
_client.Log += LogAsync;
_cmservice.Log += LogAsync;

// Tokens should be considered secret data, and never hard-coded.
await _client.LoginAsync(TokenType.Bot, Environment.GetEnvironmentVariable("token"));
await _client.StartAsync();

await _chservice.InitializeAsync();
await _thservice.UploadInputFilesAsync();

await Task.Delay(-1);
}

private Task LogAsync(LogMessage log)
{
Console.WriteLine(log.ToString());

return Task.CompletedTask;
}
}
}
8 changes: 4 additions & 4 deletions tests/NosCoreBot.Tests/NosCoreBot.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>

<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="MSTest.TestAdapter" Version="3.1.1" />
<PackageReference Include="MSTest.TestFramework" Version="3.1.1" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.0.1" />
<PackageReference Include="MSTest.TestAdapter" Version="4.0.2" />
<PackageReference Include="MSTest.TestFramework" Version="4.0.2" />
</ItemGroup>

</Project>
Loading