mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-10 09:18:27 -04:00
Namespace changes to make them make sense
This commit is contained in:
@@ -19,7 +19,7 @@ EndProjectSection
|
|||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NadekoBot", "src\NadekoBot\NadekoBot.csproj", "{45EC1473-C678-4857-A544-07DFE0D0B478}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NadekoBot", "src\NadekoBot\NadekoBot.csproj", "{45EC1473-C678-4857-A544-07DFE0D0B478}"
|
||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NadekoBot.Voice", "src\ayu\NadekoBot.Voice\NadekoBot.Voice.csproj", "{2F4CF6D6-0C2F-4944-B204-9508CDA53195}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NadekoBot.Voice", "src\NadekoBot.Voice\NadekoBot.Voice.csproj", "{2F4CF6D6-0C2F-4944-B204-9508CDA53195}"
|
||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NadekoBot.Tests", "src\NadekoBot.Tests\NadekoBot.Tests.csproj", "{DB448DD4-C97F-40E9-8BD3-F605FF1FF833}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NadekoBot.Tests", "src\NadekoBot.Tests\NadekoBot.Tests.csproj", "{DB448DD4-C97F-40E9-8BD3-F605FF1FF833}"
|
||||||
EndProject
|
EndProject
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Overridden to implement custom checks which commands have to pass in order to be executed.
|
/// Overridden to implement custom checks which commands have to pass in order to be executed.
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Used as a marker class for bot_perm and user_perm Attributes
|
/// Used as a marker class for bot_perm and user_perm Attributes
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
[AttributeUsage(AttributeTargets.Method)]
|
[AttributeUsage(AttributeTargets.Method)]
|
||||||
public sealed class bot_owner_onlyAttribute : MedusaPermAttribute
|
public sealed class bot_owner_onlyAttribute : MedusaPermAttribute
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
[AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
|
[AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
|
||||||
public sealed class bot_permAttribute : MedusaPermAttribute
|
public sealed class bot_permAttribute : MedusaPermAttribute
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Marks a method as a snek command
|
/// Marks a method as a snek command
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Marks services in command arguments for injection.
|
/// Marks services in command arguments for injection.
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Marks the parameter to take
|
/// Marks the parameter to take
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Sets the priority of a command in case there are multiple commands with the same name but different parameters.
|
/// Sets the priority of a command in case there are multiple commands with the same name but different parameters.
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Marks the class as a service which can be used within the same Medusa
|
/// Marks the class as a service which can be used within the same Medusa
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
[AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
|
[AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
|
||||||
public sealed class user_permAttribute : MedusaPermAttribute
|
public sealed class user_permAttribute : MedusaPermAttribute
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
using NadekoBot;
|
using NadekoBot;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Commands which take this class as a first parameter can be executed in both DMs and Servers
|
/// Commands which take this class as a first parameter can be executed in both DMs and Servers
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Commands which take this type as the first parameter can only be executed in DMs
|
/// Commands which take this type as the first parameter can only be executed in DMs
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Commands which take this type as a first parameter can only be executed in a server
|
/// Commands which take this type as a first parameter can only be executed in a server
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace NadekoBot;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public static class EmbedBuilderExtensions
|
public static class EmbedBuilderExtensions
|
||||||
{
|
{
|
||||||
|
@@ -1,7 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
using Nadeko.Snake;
|
|
||||||
|
|
||||||
namespace NadekoBot;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public static class MedusaExtensions
|
public static class MedusaExtensions
|
||||||
{
|
{
|
||||||
|
@@ -15,6 +15,6 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition=" '$(Version)' == '' ">
|
<PropertyGroup Condition=" '$(Version)' == '' ">
|
||||||
<Version>6.0.0</Version>
|
<Version>9.0.0</Version>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Overridden to implement parsers for custom types
|
/// Overridden to implement parsers for custom types
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public readonly struct ParseResult<T>
|
public readonly struct ParseResult<T>
|
||||||
{
|
{
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The base class which will be loaded as a module into NadekoBot
|
/// The base class which will be loaded as a module into NadekoBot
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using YamlDotNet.Serialization;
|
using YamlDotNet.Serialization;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public readonly struct CommandStrings
|
public readonly struct CommandStrings
|
||||||
{
|
{
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Defines methods to retrieve and reload medusa strings
|
/// Defines methods to retrieve and reload medusa strings
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Implemented by classes which provide localized strings in their own ways
|
/// Implemented by classes which provide localized strings in their own ways
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public class LocalMedusaStringsProvider : IMedusaStringsProvider
|
public class LocalMedusaStringsProvider : IMedusaStringsProvider
|
||||||
{
|
{
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using Serilog;
|
using Serilog;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public class MedusaStrings : IMedusaStrings
|
public class MedusaStrings : IMedusaStrings
|
||||||
{
|
{
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
using Serilog;
|
using Serilog;
|
||||||
using YamlDotNet.Serialization;
|
using YamlDotNet.Serialization;
|
||||||
|
|
||||||
namespace Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Loads strings from the shortcut or localizable path
|
/// Loads strings from the shortcut or localizable path
|
||||||
|
@@ -12,7 +12,6 @@ global using Nadeko.Common; // new project
|
|||||||
global using NadekoBot.Common; // old + nadekobot specific things
|
global using NadekoBot.Common; // old + nadekobot specific things
|
||||||
global using NadekoBot.Common.Attributes;
|
global using NadekoBot.Common.Attributes;
|
||||||
global using NadekoBot.Extensions;
|
global using NadekoBot.Extensions;
|
||||||
// global using Nadeko.Snake;
|
|
||||||
|
|
||||||
// discord
|
// discord
|
||||||
global using Discord;
|
global using Discord;
|
||||||
|
@@ -118,7 +118,7 @@ public class CryptoService : INService
|
|||||||
|
|
||||||
var nearest = cryptos
|
var nearest = cryptos
|
||||||
.Select(elem => (Elem: elem,
|
.Select(elem => (Elem: elem,
|
||||||
Distance: StringExtensions.LevenshteinDistance(elem.Name.ToUpperInvariant(), name)))
|
Distance: elem.Name.ToUpperInvariant().LevenshteinDistance(name)))
|
||||||
.OrderBy(x => x.Distance)
|
.OrderBy(x => x.Distance)
|
||||||
.FirstOrDefault(x => x.Distance <= 2);
|
.FirstOrDefault(x => x.Distance <= 2);
|
||||||
|
|
||||||
|
@@ -94,8 +94,7 @@ public sealed class ImagesharpStockChartDrawingService : IStockChartDrawingServi
|
|||||||
=> image.Mutate(ctx =>
|
=> image.Mutate(ctx =>
|
||||||
{
|
{
|
||||||
foreach (var data in drawData)
|
foreach (var data in drawData)
|
||||||
DrawLineExtensions.DrawLines(ctx,
|
ctx.DrawLines(data.IsGreen
|
||||||
data.IsGreen
|
|
||||||
? _greenBrush
|
? _greenBrush
|
||||||
: _redBrush,
|
: _redBrush,
|
||||||
1,
|
1,
|
||||||
@@ -104,8 +103,7 @@ public sealed class ImagesharpStockChartDrawingService : IStockChartDrawingServi
|
|||||||
|
|
||||||
|
|
||||||
foreach (var data in drawData)
|
foreach (var data in drawData)
|
||||||
FillRectangleExtensions.Fill(ctx,
|
ctx.Fill(data.IsGreen
|
||||||
data.IsGreen
|
|
||||||
? _greenBrush
|
? _greenBrush
|
||||||
: _redBrush,
|
: _redBrush,
|
||||||
data.BodyRect);
|
data.BodyRect);
|
||||||
|
@@ -3,6 +3,7 @@ using Humanizer.Localisation;
|
|||||||
using NadekoBot.Db;
|
using NadekoBot.Db;
|
||||||
using NadekoBot.Modules.Utility.Services;
|
using NadekoBot.Modules.Utility.Services;
|
||||||
using NadekoBot.Db.Models;
|
using NadekoBot.Db.Models;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
namespace NadekoBot.Modules.Utility;
|
namespace NadekoBot.Modules.Utility;
|
||||||
|
|
||||||
@@ -43,7 +44,7 @@ public partial class Utility
|
|||||||
await ReplyErrorLocalizedAsync(strs.remind_invalid);
|
await ReplyErrorLocalizedAsync(strs.remind_invalid);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
ulong target;
|
ulong target;
|
||||||
target = meorhere == MeOrHere.Me ? ctx.User.Id : ctx.Channel.Id;
|
target = meorhere == MeOrHere.Me ? ctx.User.Id : ctx.Channel.Id;
|
||||||
if (!await RemindInternal(target,
|
if (!await RemindInternal(target,
|
||||||
|
@@ -5,7 +5,6 @@
|
|||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<ImplicitUsings>true</ImplicitUsings>
|
<ImplicitUsings>true</ImplicitUsings>
|
||||||
<Version>5.0.0</Version>
|
<Version>5.0.0</Version>
|
||||||
<VersionSuffix>beta1</VersionSuffix>
|
|
||||||
|
|
||||||
<!-- Output/build -->
|
<!-- Output/build -->
|
||||||
<RunWorkingDirectory>$(MSBuildProjectDirectory)</RunWorkingDirectory>
|
<RunWorkingDirectory>$(MSBuildProjectDirectory)</RunWorkingDirectory>
|
||||||
@@ -76,7 +75,7 @@
|
|||||||
<PackageReference Include="SixLabors.Shapes" Version="1.0.0-beta0009" />
|
<PackageReference Include="SixLabors.Shapes" Version="1.0.0-beta0009" />
|
||||||
<PackageReference Include="StackExchange.Redis" Version="2.7.33" />
|
<PackageReference Include="StackExchange.Redis" Version="2.7.33" />
|
||||||
<PackageReference Include="YamlDotNet" Version="15.1.2" />
|
<PackageReference Include="YamlDotNet" Version="15.1.2" />
|
||||||
<PackageReference Include="SharpToken" Version="1.2.14" />
|
<PackageReference Include="SharpToken" Version="2.0.2" />
|
||||||
|
|
||||||
<PackageReference Include="Humanizer" Version="2.14.1">
|
<PackageReference Include="Humanizer" Version="2.14.1">
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
@@ -110,9 +109,8 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\ayu\NadekoBot.Voice\NadekoBot.Voice.csproj" />
|
|
||||||
<ProjectReference Include="..\Nadeko.Medusa\Nadeko.Medusa.csproj" />
|
<ProjectReference Include="..\Nadeko.Medusa\Nadeko.Medusa.csproj" />
|
||||||
|
<ProjectReference Include="..\NadekoBot.Voice\NadekoBot.Voice.csproj" />
|
||||||
<ProjectReference Include="..\NadekoBot.Generators\NadekoBot.Generators.csproj" OutputItemType="Analyzer" />
|
<ProjectReference Include="..\NadekoBot.Generators\NadekoBot.Generators.csproj" OutputItemType="Analyzer" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
@@ -133,16 +131,6 @@
|
|||||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
|
||||||
<Folder Include="data\medusae\" />
|
|
||||||
<Folder Include="_common\Extensions\" />
|
|
||||||
</ItemGroup>
|
|
||||||
|
|
||||||
<!-- <PropertyGroup Condition=" '$(Version)' == '' ">-->
|
|
||||||
<!-- <VersionPrefix Condition=" '$(VersionPrefix)' == '' ">5.0.0</VersionPrefix>-->
|
|
||||||
<!-- <Version Condition=" '$(VersionSuffix)' != '' ">$(VersionPrefix).$(VersionSuffix)</Version>-->
|
|
||||||
<!-- <Version Condition=" '$(Version)' == '' ">$(VersionPrefix)</Version>-->
|
|
||||||
<!-- </PropertyGroup>-->
|
|
||||||
|
|
||||||
<PropertyGroup Condition=" '$(Configuration)' == 'GlobalNadeko' ">
|
<PropertyGroup Condition=" '$(Configuration)' == 'GlobalNadeko' ">
|
||||||
<!-- Define trace doesn't seem to affect the build at all so I had to remove $(DefineConstants)-->
|
<!-- Define trace doesn't seem to affect the build at all so I had to remove $(DefineConstants)-->
|
||||||
|
@@ -1,3 +1,6 @@
|
|||||||
|
using Humanizer.Localisation;
|
||||||
|
using System.Resources;
|
||||||
|
|
||||||
var pid = Environment.ProcessId;
|
var pid = Environment.ProcessId;
|
||||||
|
|
||||||
var shardId = 0;
|
var shardId = 0;
|
||||||
|
@@ -28,7 +28,7 @@ public class YamlSeria : IConfigSeria
|
|||||||
me =>
|
me =>
|
||||||
{
|
{
|
||||||
var str = me.Groups["code"].Value;
|
var str = me.Groups["code"].Value;
|
||||||
var newString = YamlHelper.UnescapeUnicodeCodePoint(str);
|
var newString = str.UnescapeUnicodeCodePoint();
|
||||||
return newString;
|
return newString;
|
||||||
});
|
});
|
||||||
return output;
|
return output;
|
||||||
|
@@ -131,7 +131,7 @@ public static class StringExtensions
|
|||||||
me =>
|
me =>
|
||||||
{
|
{
|
||||||
var str = me.Groups["code"].Value;
|
var str = me.Groups["code"].Value;
|
||||||
var newString = YamlHelper.UnescapeUnicodeCodePoint(str);
|
var newString = str.UnescapeUnicodeCodePoint();
|
||||||
return newString;
|
return newString;
|
||||||
});
|
});
|
||||||
}
|
}
|
@@ -1,6 +1,4 @@
|
|||||||
#nullable enable
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
using Nadeko.Snake;
|
|
||||||
|
|
||||||
[DIIgnore]
|
[DIIgnore]
|
||||||
public sealed class BehaviorAdapter : ICustomBehavior
|
public sealed class BehaviorAdapter : ICustomBehavior
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
internal class ContextAdapterFactory
|
internal class ContextAdapterFactory
|
||||||
{
|
{
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class DmContextAdapter : DmContext
|
public sealed class DmContextAdapter : DmContext
|
||||||
{
|
{
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
namespace Nadeko.Medusa.Adapters;
|
namespace Nadeko.Medusa.Adapters;
|
||||||
|
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class GuildContextAdapter : GuildContext
|
public sealed class GuildContextAdapter : GuildContext
|
||||||
{
|
{
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class ParamParserAdapter<T> : TypeReader
|
public sealed class ParamParserAdapter<T> : TypeReader
|
||||||
{
|
{
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Enum specifying in which context the command can be executed
|
/// Enum specifying in which context the command can be executed
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public interface IMedusaConfigService
|
public interface IMedusaConfigService
|
||||||
{
|
{
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
using Cloneable;
|
using Cloneable;
|
||||||
using NadekoBot.Common.Yml;
|
using NadekoBot.Common.Yml;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
[Cloneable]
|
[Cloneable]
|
||||||
public sealed partial class MedusaConfig : ICloneable<MedusaConfig>
|
public sealed partial class MedusaConfig : ICloneable<MedusaConfig>
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
using NadekoBot.Common.Configs;
|
using NadekoBot.Common.Configs;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class MedusaConfigService : ConfigServiceBase<MedusaConfig>, IMedusaConfigService
|
public sealed class MedusaConfigService : ConfigServiceBase<MedusaConfig>, IMedusaConfigService
|
||||||
{
|
{
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.Loader;
|
using System.Runtime.Loader;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public class MedusaAssemblyLoadContext : AssemblyLoadContext
|
public class MedusaAssemblyLoadContext : AssemblyLoadContext
|
||||||
{
|
{
|
||||||
|
@@ -1,5 +1,4 @@
|
|||||||
using Nadeko.Snake;
|
using System.Reflection;
|
||||||
using System.Reflection;
|
|
||||||
using Ninject;
|
using Ninject;
|
||||||
using Ninject.Activation;
|
using Ninject.Activation;
|
||||||
using Ninject.Activation.Caching;
|
using Ninject.Activation.Caching;
|
||||||
@@ -7,7 +6,7 @@ using Ninject.Modules;
|
|||||||
using Ninject.Planning;
|
using Ninject.Planning;
|
||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class MedusaNinjectModule : NinjectModule
|
public sealed class MedusaNinjectModule : NinjectModule
|
||||||
{
|
{
|
||||||
|
@@ -10,9 +10,8 @@ using System.Diagnostics.CodeAnalysis;
|
|||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
using System.Runtime.CompilerServices;
|
||||||
using Nadeko.Snake;
|
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
// ReSharper disable RedundantAssignment
|
// ReSharper disable RedundantAssignment
|
||||||
public sealed class MedusaLoaderService : IMedusaLoaderService, IReadyExecutor, INService
|
public sealed class MedusaLoaderService : IMedusaLoaderService, IReadyExecutor, INService
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed record ParamData(
|
public sealed record ParamData(
|
||||||
Type Type,
|
Type Type,
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
using Ninject.Modules;
|
using Ninject.Modules;
|
||||||
using System.Collections.Immutable;
|
using System.Collections.Immutable;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed record ResolvedMedusa(
|
public sealed record ResolvedMedusa(
|
||||||
WeakReference<MedusaAssemblyLoadContext> LoadContext,
|
WeakReference<MedusaAssemblyLoadContext> LoadContext,
|
||||||
|
@@ -1,8 +1,7 @@
|
|||||||
using Nadeko.Snake;
|
using NadekoBot.Medusa;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using CommandStrings = Nadeko.Snake.CommandStrings;
|
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
public sealed class SnekCommandData
|
public sealed class SnekCommandData
|
||||||
{
|
{
|
||||||
|
@@ -1,6 +1,4 @@
|
|||||||
using Nadeko.Snake;
|
namespace NadekoBot.Medusa;
|
||||||
|
|
||||||
namespace Nadeko.Medusa;
|
|
||||||
|
|
||||||
public sealed record SnekInfo(
|
public sealed record SnekInfo(
|
||||||
string Name,
|
string Name,
|
||||||
|
@@ -86,7 +86,7 @@ public abstract class NadekoModule : ModuleBase
|
|||||||
embed.WithPendingColor()
|
embed.WithPendingColor()
|
||||||
.WithFooter("yes/no");
|
.WithFooter("yes/no");
|
||||||
|
|
||||||
var msg = await MessageChannelExtensions.EmbedAsync(ctx.Channel, embed);
|
var msg = await ctx.Channel.EmbedAsync(embed);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var input = await GetUserInputAsync(ctx.User.Id, ctx.Channel.Id);
|
var input = await GetUserInputAsync(ctx.User.Id, ctx.Channel.Id);
|
||||||
|
Reference in New Issue
Block a user