Fixed some stuff, updated discord.net
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -13,6 +13,7 @@ obj/
|
|||||||
*.userprefs
|
*.userprefs
|
||||||
**/src/NadekoBot/bin
|
**/src/NadekoBot/bin
|
||||||
Tests/bin
|
Tests/bin
|
||||||
|
src/NadekoBot/credentials.json
|
||||||
|
|
||||||
# NuGet Packages
|
# NuGet Packages
|
||||||
*.nupkg
|
*.nupkg
|
||||||
|
Submodule discord.net updated: a76956c8ef...f531c63499
@@ -57,7 +57,7 @@ namespace NadekoBot
|
|||||||
depMap.Add<IYoutubeService>(Youtube);
|
depMap.Add<IYoutubeService>(Youtube);
|
||||||
|
|
||||||
//connect
|
//connect
|
||||||
await Client.LoginAsync(TokenType.Bot, "MTE5Nzc3MDIxMzE5NTc3NjEw.CpdrFA.0rex01uCrn9dBTJOV2tXwMLo0wE");
|
await Client.LoginAsync(TokenType.Bot, Credentials.Token);
|
||||||
await Client.ConnectAsync();
|
await Client.ConnectAsync();
|
||||||
|
|
||||||
_log.Info("Connected");
|
_log.Info("Connected");
|
||||||
|
6
src/NadekoBot/NuGet.Config
Normal file
6
src/NadekoBot/NuGet.Config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<packageSources>
|
||||||
|
<add key=".Net Core" value="https://dotnet.myget.org/F/dotnet-core/api/v3/index.json" />
|
||||||
|
</packageSources>
|
||||||
|
</configuration>
|
@@ -1,5 +1,7 @@
|
|||||||
using System;
|
using Newtonsoft.Json;
|
||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
|
|
||||||
namespace NadekoBot.Services.Impl
|
namespace NadekoBot.Services.Impl
|
||||||
{
|
{
|
||||||
@@ -8,18 +10,21 @@ namespace NadekoBot.Services.Impl
|
|||||||
{
|
{
|
||||||
public string ClientId { get; }
|
public string ClientId { get; }
|
||||||
|
|
||||||
public string GoogleApiKey {
|
public string GoogleApiKey { get; }
|
||||||
get {
|
|
||||||
return "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public IEnumerable<string> MashapeKey { get; }
|
public IEnumerable<string> MashapeKey { get; }
|
||||||
|
|
||||||
public string Token {
|
public string Token { get; }
|
||||||
get {
|
|
||||||
return "";
|
|
||||||
}
|
public BotCredentials()
|
||||||
|
{
|
||||||
|
var cm = JsonConvert.DeserializeObject<CredentialsModel>(File.ReadAllText("./credentials.json"));
|
||||||
|
Token = cm.Token;
|
||||||
|
}
|
||||||
|
|
||||||
|
private class CredentialsModel {
|
||||||
|
public string Token { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -1,5 +1,8 @@
|
|||||||
{
|
{
|
||||||
"version": "1.0.0-*",
|
"version": "1.0.0-*",
|
||||||
|
"description": "General purposee Discord bot written in C#.",
|
||||||
|
"authors": [ "Kwoth" ],
|
||||||
|
"copyright": "Kwoth",
|
||||||
"buildOptions": {
|
"buildOptions": {
|
||||||
"emitEntryPoint": true,
|
"emitEntryPoint": true,
|
||||||
"compile": {
|
"compile": {
|
||||||
|
Reference in New Issue
Block a user