Remvoed secrets for Twitch since they don't work
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
using ABI.System;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using System.Diagnostics;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
@@ -14,9 +12,8 @@ namespace TwitchDesktopNotifications.Core
|
||||
internal class TwitchFetcher
|
||||
{
|
||||
private TwitchFetcher() {
|
||||
var config = new ConfigurationBuilder().AddUserSecrets<Program>().Build();
|
||||
TwitchClientID = config["TwitchClientID"];
|
||||
TwitchClientSecret = config["TwitchClientSecret"];
|
||||
TwitchClientID = "";
|
||||
TwitchClientSecret = "";
|
||||
}
|
||||
|
||||
public static TwitchFetcher instance { get; private set; }
|
||||
|
||||
@@ -40,6 +40,10 @@ namespace TwitchDesktopNotifications
|
||||
String FileName = "store.json";
|
||||
|
||||
string fileContent = JsonSerializer.Serialize<JsonStructure.Store>(Store);
|
||||
|
||||
Console.WriteLine("I'm trying to save:");
|
||||
Console.WriteLine(fileContent);
|
||||
Console.WriteLine("to {0}", FilePath + "/" + FileName);
|
||||
Directory.CreateDirectory(FilePath);
|
||||
File.WriteAllText(FilePath + "/" + FileName, fileContent);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// See https://aka.ms/new-console-template for more information
|
||||
using System.Drawing;
|
||||
using System.Reflection.Metadata;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text.Json;
|
||||
using System.Windows.Controls;
|
||||
@@ -18,7 +19,6 @@ internal class Program
|
||||
private static NotifyIcon notifyIcon;
|
||||
private static ContextMenuStrip cms;
|
||||
|
||||
|
||||
public static void Ws_CodeRecived(object? sender, EventArgs e)
|
||||
{
|
||||
ws.CodeRecived -= Ws_CodeRecived;
|
||||
@@ -73,12 +73,14 @@ internal class Program
|
||||
}
|
||||
|
||||
private static async Task Main(string[] args)
|
||||
{
|
||||
try
|
||||
{
|
||||
var timer = new PeriodicTimer(TimeSpan.FromSeconds(10));
|
||||
|
||||
notifyIcon = new NotifyIcon();
|
||||
notifyIcon.Icon = new Icon("Assets/icon.ico");
|
||||
notifyIcon.Text = "Notify";
|
||||
notifyIcon.Text = "Twitch Notify";
|
||||
|
||||
cms = new ContextMenuStrip();
|
||||
|
||||
@@ -104,6 +106,10 @@ internal class Program
|
||||
}).Start();
|
||||
|
||||
Application.Run();
|
||||
}
|
||||
catch (Exception e) {
|
||||
Console.WriteLine(e.ToString());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0-windows10.0.17763.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
@@ -19,7 +19,6 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration.UserSecrets" Version="7.0.0" />
|
||||
<PackageReference Include="Microsoft.Toolkit.Uwp.Notifications" Version="8.0.0-build.65" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user