diff --git a/.github/workflows/docs-preview.yml b/.github/workflows/docs-preview.yml
index bf9c20a63..bca7812ca 100644
--- a/.github/workflows/docs-preview.yml
+++ b/.github/workflows/docs-preview.yml
@@ -1,56 +1,55 @@
name: Docs Preview
on:
pull_request:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
path: DisCatSharp
- uses: actions/checkout@v2
with:
repository: Aiko-IT-Systems/DisCatSharp.Docs.Preview
path: DisCatSharp.Docs.Preview
token: ${{ secrets.DOCS_TOKEN }}
- name: Show Dir
run: dir
- name: Build Docs
working-directory: ./DisCatSharp
shell: pwsh
run: |
./rebuild-docs.ps1 -DocsPath "./DisCatSharp.Docs" -Output ".." -PackageName "dcs-docs-preview"
- name: Archive Docs
uses: actions/upload-artifact@v2
with:
name: preview-docs
path: dcs-docs-preview.tar.xz
- name: Purge old docs
working-directory: ./DisCatSharp.Docs.Preview
run: |
shopt -s extglob
rm -rf !(.git|.gitignore)
- name: Extract new docs
run: |
tar -xf dcs-docs-preview.tar.xz -C ./DisCatSharp.Docs.Preview
- name: Commit and push changes
uses: EndBug/add-and-commit@master
with:
cwd: ./DisCatSharp.Docs.Preview
default_author: github_actions
author_name: DisCatSharp
author_email: discatsharp@aitsys.dev
message: 'Preview docs (${{ github.sha }})'
- pull: 'NO-PULL'
diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml
index 4cd6d1040..d91360631 100644
--- a/.github/workflows/dotnet.yml
+++ b/.github/workflows/dotnet.yml
@@ -1,25 +1,30 @@
name: "DisCatSharp .NET"
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
+ workflow_dispatch:
jobs:
build:
-
- runs-on: ubuntu-latest
-
+ strategy:
+ matrix:
+ os: [ubuntu-latest, macos-latest, windows-latest]
+ dotnet: [6.0.x]
+
+ runs-on: ${{ matrix.os }}
+
steps:
- uses: actions/checkout@v2
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
- dotnet-version: 5.0.x
+ dotnet-version: ${{ matrix.dotnet }}
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
diff --git a/DisCatSharp.Common/DisCatSharp.Common.csproj b/DisCatSharp.Common/DisCatSharp.Common.csproj
index 2ba59dad9..04fdce4bb 100644
--- a/DisCatSharp.Common/DisCatSharp.Common.csproj
+++ b/DisCatSharp.Common/DisCatSharp.Common.csproj
@@ -1,46 +1,54 @@
DisCatSharp.Common
DisCatSharp.Common
9.0
True
True
True
Portable
Library
netstandard2.0
DisCatSharp.Common
Assortment of various common types and utilities for DisCatSharp's projects.
common utilities dotnet dotnet-core dotnetfx netfx netcore csharp
LICENSE.MD
False
+
+ 1701;1702;;DV2001
+
+
+
+ 1701;1702;;DV2001
+
+
True
diff --git a/DisCatSharp.Configuration.Tests/DisCatSharp.Configuration.Tests.csproj b/DisCatSharp.Configuration.Tests/DisCatSharp.Configuration.Tests.csproj
index 3670f5648..8d476d34e 100644
--- a/DisCatSharp.Configuration.Tests/DisCatSharp.Configuration.Tests.csproj
+++ b/DisCatSharp.Configuration.Tests/DisCatSharp.Configuration.Tests.csproj
@@ -1,53 +1,53 @@
- net5.0
+ net6.0
enable
1591;NU5128;DV2001
false
false
runtime; build; native; contentfiles; analyzers; buildtransitive
all
runtime; build; native; contentfiles; analyzers; buildtransitive
all
Always
Always
Always
Always
Always
Always
diff --git a/DisCatSharp.Hosting.Tests/DisCatSharp.Hosting.Tests.csproj b/DisCatSharp.Hosting.Tests/DisCatSharp.Hosting.Tests.csproj
index 1786143e5..dffcfbdc4 100644
--- a/DisCatSharp.Hosting.Tests/DisCatSharp.Hosting.Tests.csproj
+++ b/DisCatSharp.Hosting.Tests/DisCatSharp.Hosting.Tests.csproj
@@ -1,49 +1,49 @@
- net5.0
+ net6.0
enable
1591;NU5128;DV2001
false
false
runtime; build; native; contentfiles; analyzers; buildtransitive
all
runtime; build; native; contentfiles; analyzers; buildtransitive
all
Always
Always
Always
Always
diff --git a/README.md b/README.md
index b166a4db7..9331ba78c 100644
--- a/README.md
+++ b/README.md
@@ -1,99 +1,100 @@
# DisCatSharp [![GitHub](https://img.shields.io/github/license/Aiko-IT-Systems/DisCatSharp?label=License)](https://github.com/Aiko-IT-Systems/DisCatSharp/blob/main/LICENSE.md) [![Sponsors](https://img.shields.io/github/sponsors/Lulalaby?label=Sponsors)](https://github.com/sponsors/Lulalaby) [![Discord Server](https://img.shields.io/discord/858089281214087179.svg?label=Discord)](https://discord.gg/discatsharp)
![Logo](DisCatSharp.Logos/logobig.png#64x64)
[Discord Bot Library](https://discord.gg/discatsharp) written in C# for .NET.
#### Status
[![NuGet](https://img.shields.io/nuget/v/DisCatSharp.svg?label=NuGet%20Overall%20Version)](https://nuget.dcs.aitsys.dev)
[![Build status](https://ci.appveyor.com/api/projects/status/fy4xn9s3cq7j30j7/branch/main?svg=true)](https://ci.appveyor.com/project/AITSYS/discatsharp/branch/main)
#### Commit Activities
[![GitHub last commit](https://img.shields.io/github/last-commit/Aiko-IT-Systems/DisCatSharp?label=Last%20Commit)](https://aitsys.dev/source/DisCatSharp/history/)
[![GitHub commit activity](https://img.shields.io/github/commit-activity/w/Aiko-IT-Systems/DisCatSharp?label=Commit%20Activity)](https://github.com/Aiko-IT-Systems/DisCatSharp/commits/main)
[![wakatime](https://wakatime.com/badge/github/Aiko-IT-Systems/DisCatSharp.svg)](https://wakatime.com/badge/github/Aiko-IT-Systems/DisCatSharp)
#### Stats
[![GitHub pull requests](https://img.shields.io/github/issues-pr/Aiko-IT-Systems/DisCatSharp?label=PRs)](https://github.com/Aiko-IT-Systems/DisCatSharp/pulls)
[![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/Aiko-IT-Systems/DisCatSharp?label=Size)](#)
[![GitHub contributors](https://img.shields.io/github/contributors/Aiko-IT-Systems/DisCatSharp)](https://github.com/Aiko-IT-Systems/DisCatSharp/graphs/contributors)
[![GitHub Repo stars](https://img.shields.io/github/stars/Aiko-IT-Systems/DisCatSharp?label=Stars)](https://github.com/Aiko-IT-Systems/DisCatSharp/stargazers)
[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/5282/badge)](https://bestpractices.coreinfrastructure.org/projects/5282)
[![StackShare](http://img.shields.io/badge/tech-stack-0690fa.svg?style=flat)](https://stackshare.io/aiko-it-systems/discatsharp)
## Why DisCatSharp?
We want the lib always up-to-date. The newest features are important for us.
So the API version is always the newest, in the actual case `v9`.
## Where is the Changelog?
On our guild! You find it in [this channel](https://discord.com/channels/858089281214087179/858099438580006913).
## Installing
You can install the library from following source:
The latest release is always available on [NuGet](https://nuget.dcs.aitsys.dev).
## Documentation
The documentation for the latest stable version is available at [docs.dcs.aitsys.dev/lts](https://docs.dcs.aitsys.dev/lts).
The documentation of the latest nightly versions is available at [docs.dcs.aitsys.dev](https://docs.dcs.aitsys.dev).
## Bugs or Feature requests?
Either join our [support guild](https://discord.gg/discatsharp) and open a support ticket.
Or write a mail to dcs@aitsys.dev.
All requests are tracked at [aitsys.dev](https://aitsys.dev).
## Tutorials
* [Howto](https://docs.dcs.aitsys.dev/articles/basics/bot_account.html)
* [Examples](https://examples.dcs.aitsys.dev)
## Snippts
[Snippets for Visual Studio](https://github.com/Aiko-IT-Systems/DisCatSharp.Snippets)
## Latest NuGet Packages
| Package | NuGet |
| --------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| DisCatSharp | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp) |
| DisCatSharp.ApplicationCommands | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.ApplicationCommands.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.ApplicationCommands) |
| DisCatSharp.CommandsNext | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.CommandsNext.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.CommandsNext) |
| DisCatSharp.Common | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Common.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Common) |
| DisCatSharp.Configuration | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Configuration.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Configuration) |
| DisCatSharp.Hosting | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Hosting.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Hosting) |
| DisCatSharp.Hosting.DependencyInjection | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Hosting.DependencyInjection.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Hosting.DependencyInjection) |
| DisCatSharp.Interactivity | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Interactivity.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Interactivity) |
| DisCatSharp.Lavalink | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.Lavalink.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.Lavalink) |
| DisCatSharp.VoiceNext | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.VoiceNext.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.VoiceNext) |
| DisCatSharp.VoiceNext.Natives | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.VoiceNext.Natives.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.VoiceNext.Natives) |
+| DisCatSharp.ProjectTemplates | [![NuGet](https://img.shields.io/nuget/v/DisCatSharp.ProjectTemplates.svg?label=)](https://nuget.dcs.aitsys.dev/DisCatSharp.ProjectTemplates) |
## Releasing
To release a new version do the following steps:
- Create locally a repo named `release/VERSION` (Don't forget to replace VERSION with the target version number)
- Replace version number with the correct version in [appveyor.yml#L78](https://github.com/Aiko-IT-Systems/DisCatSharp/blob/main/appveyor.yml#L78) with the new release number and [appveyor.yml#L5](https://github.com/Aiko-IT-Systems/DisCatSharp/blob/main/appveyor.yml#L5) with the next-ahead release number.
- Replace nuget version number in [Version.targets#L4](https://github.com/Aiko-IT-Systems/DisCatSharp/blob/main/Version.targets#L4)
- Publish branch to GitHub
- Wait for the CI/CD to complete.
- Merge the branch into main and delete it afterwards
## Testing Docs
Just visit [this](https://github.com/Aiko-IT-Systems/DisCatSharp/actions/workflows/docs-preview.yml) Workflow.
The workflow generates a docs artifact and deploys on Cloudflare Pages.
Visit the channel [#github-feed](https://discord.com/channels/858089281214087179/861507952509976607) on discord and watch for this message:
![Deploy](./cf-deploy.png)
If you can't see it, take a look into the selfroles channel.
## Thanks
Big thanks goes to the following people who helps us ♥️
- [Auros Nexus](https://github.com/Auros)
- [Lunar Starstrum](https://github.com/OoLunar)
- [Johannes](https://github.com/JMLutra)
- [Geferon](https://github.com/geferon)
- [Alice](https://github.com/QuantuChi)
## Special Thanks
The special thanks goes to Nagisa. Make sure to check out her [instagram](https://www.instagram.com/nagisaarts_/) ♥️♥️
diff --git a/appveyor.yml b/appveyor.yml
index 854b93569..29e646bde 100644
--- a/appveyor.yml
+++ b/appveyor.yml
@@ -1,140 +1,140 @@
-
branches:
only:
- main
version: 9.8.5-nightly-{build}
pull_requests:
do_not_increment_build_number: true
skip_tags: true
max_jobs: 1
- image: Visual Studio 2019
+ image: Visual Studio 2022
clone_depth: 1
build_script:
- ps: |-
# Version number
$BUILD_NUMBER = [int]$Env:APPVEYOR_BUILD_NUMBER
$BUILD_SUFFIX = "nightly"
# Branch
$BRANCH = "$Env:APPVEYOR_REPO_BRANCH"
$Env:DOCFX_SOURCE_BRANCH_NAME = "$BRANCH"
# Output directory
$Env:ARTIFACT_DIR = ".\artifacts"
$dir = New-Item -type directory $env:ARTIFACT_DIR
$dir = $dir.FullName
# Verbosity
Write-Host "Build: $BUILD_NUMBER / Branch: $BRANCH"
Write-Host "Artifacts will be placed in: $dir"
# Check if this is a PR
if (-not $Env:APPVEYOR_PULL_REQUEST_NUMBER)
{
Write-Host "Commencing complete build"
& .\rebuild-all.ps1 -ArtifactLocation "$dir" -Configuration "Release" -VersionSuffix "$BUILD_SUFFIX" -BuildNumber $BUILD_NUMBER
& Remove-Item "$dir\*.symbols.nupkg"
}
else
{
Write-Host "Building from PR ($Env:APPVEYOR_PULL_REQUEST_NUMBER)"
& .\rebuild-all.ps1 -ArtifactLocation "$dir" -Configuration "Release" -VersionSuffix "$BUILD_SUFFIX" -BuildNumber $BUILD_NUMBER
& Remove-Item "$dir\*.symbols.nupkg"
}
artifacts:
- path: artifacts\*.snupkg
- path: artifacts\*.nupkg
- path: artifacts\dcs-docs.tar.xz
deploy:
- provider: NuGet
server:
api_key:
secure: eml4lPttwjBZg7WdwX3tbx34ZDNssgb2zwthatNbolRY0PnaCIswbuPClf9IWrw7
skip_symbols: false
- provider: GitHub
auth_token:
secure: oMF8sv9mhVjO7pBctQOwlmfd5aHQ4hvMoVCz77bgO9+1zBQSelPHxk0bCVfXNCCp
prerelease: true
force_update: true
- provider: NuGet
server: https://nuget.pkg.github.com/Aiko-IT-Systems/index.json
username: lulalaby
api_key:
secure: SBGo8KrGJ7t5wwMNHKD0WSzrQ+PLJbqXE3FtDH2yGkSrQewO+kzmwp/xGk5a84He
skip_symbols: true
on_success:
- ps: Invoke-RestMethod https://raw.githubusercontent.com/DiscordHooks/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 success $env:WEBHOOK_URL
on_failure:
- ps: Invoke-RestMethod https://raw.githubusercontent.com/DiscordHooks/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 failure $env:WEBHOOK_URL
# Releases
-
branches:
only:
- /release/
version: 9.8.4
pull_requests:
do_not_increment_build_number: true
skip_tags: true
max_jobs: 1
- image: Visual Studio 2019
+ image: Visual Studio 2022
clone_depth: 1
build_script:
- ps: |-
# Version number
$BUILD_NUMBER = [int]$Env:APPVEYOR_BUILD_NUMBER
# Branch
$BRANCH = "$Env:APPVEYOR_REPO_BRANCH"
$Env:DOCFX_SOURCE_BRANCH_NAME = "$BRANCH"
# Output directory
$Env:ARTIFACT_DIR = ".\artifacts"
$dir = New-Item -type directory $env:ARTIFACT_DIR
$dir = $dir.FullName
# Verbosity
Write-Host "Build: $BUILD_NUMBER / Branch: $BRANCH"
Write-Host "Artifacts will be placed in: $dir"
# Check if this is a PR
if (-not $Env:APPVEYOR_PULL_REQUEST_NUMBER)
{
Write-Host "Commencing complete build"
& .\rebuild-all.ps1 -ArtifactLocation "$dir" -Configuration "Release" -VersionSuffix "$BUILD_SUFFIX" -BuildNumber $BUILD_NUMBER
& Remove-Item "$dir\*.symbols.nupkg"
}
else
{
Write-Host "Building from PR ($Env:APPVEYOR_PULL_REQUEST_NUMBER)"
& .\rebuild-all.ps1 -ArtifactLocation "$dir" -Configuration "Release" -VersionSuffix "$BUILD_SUFFIX" -BuildNumber $BUILD_NUMBER
& Remove-Item "$dir\*.symbols.nupkg"
}
artifacts:
- path: artifacts\*.snupkg
- path: artifacts\*.nupkg
- path: artifacts\dcs-docs.tar.xz
deploy:
- provider: NuGet
server:
api_key:
secure: eml4lPttwjBZg7WdwX3tbx34ZDNssgb2zwthatNbolRY0PnaCIswbuPClf9IWrw7
skip_symbols: false
- provider: GitHub
auth_token:
secure: oMF8sv9mhVjO7pBctQOwlmfd5aHQ4hvMoVCz77bgO9+1zBQSelPHxk0bCVfXNCCp
prerelease: false
force_update: true
- provider: NuGet
server: https://nuget.pkg.github.com/Aiko-IT-Systems/index.json
username: lulalaby
api_key:
secure: SBGo8KrGJ7t5wwMNHKD0WSzrQ+PLJbqXE3FtDH2yGkSrQewO+kzmwp/xGk5a84He
skip_symbols: true
on_success:
- ps: Invoke-RestMethod https://raw.githubusercontent.com/DiscordHooks/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 success $env:WEBHOOK_URL
on_failure:
- ps: Invoke-RestMethod https://raw.githubusercontent.com/DiscordHooks/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 failure $env:WEBHOOK_URL
diff --git a/global.json b/global.json
new file mode 100644
index 000000000..126149e6b
--- /dev/null
+++ b/global.json
@@ -0,0 +1,6 @@
+{
+ "sdk": {
+ "version": "6.0.100",
+ "rollForward": "latestMajor"
+ }
+}