Skip to content

Commit

Permalink
Updated logs
Browse files Browse the repository at this point in the history
Added Linux and MacOS support
  • Loading branch information
GREBIAR-Git committed May 22, 2024
1 parent 81a0c99 commit edee103
Show file tree
Hide file tree
Showing 23 changed files with 312 additions and 620 deletions.
30 changes: 15 additions & 15 deletions HDRezkaMirror.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,30 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.3.32922.545
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorLauncher", "HdrezkaMirrorLauncher\HdrezkaMirrorLauncher.csproj", "{4A7E6064-CD91-43A9-AB95-169E6253262B}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorSite", "HdrezkaMirrorSite\HdrezkaMirrorSite.csproj", "{91A2AAFC-93D5-4215-AE11-8733AF1597B8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorSite", "HdrezkaMirrorSite\HdrezkaMirrorSite.csproj", "{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorConfigLauncher", "HdrezkaMirrorConfigLauncher\HdrezkaMirrorConfigLauncher.csproj", "{1050A713-995F-4505-80D9-2E5DDB9F6769}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorConfigLauncher", "HdrezkaMirrorConfigLauncher\HdrezkaMirrorConfigLauncher.csproj", "{57E755E4-B9BA-4771-B752-5F77CD2991B2}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HdrezkaMirrorLauncher", "HdrezkaMirrorLauncher\HdrezkaMirrorLauncher.csproj", "{09E0E9AD-EAFD-4A03-94D0-29C60FEC3547}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{4A7E6064-CD91-43A9-AB95-169E6253262B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4A7E6064-CD91-43A9-AB95-169E6253262B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4A7E6064-CD91-43A9-AB95-169E6253262B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4A7E6064-CD91-43A9-AB95-169E6253262B}.Release|Any CPU.Build.0 = Release|Any CPU
{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}.Release|Any CPU.Build.0 = Release|Any CPU
{57E755E4-B9BA-4771-B752-5F77CD2991B2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{57E755E4-B9BA-4771-B752-5F77CD2991B2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{57E755E4-B9BA-4771-B752-5F77CD2991B2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{57E755E4-B9BA-4771-B752-5F77CD2991B2}.Release|Any CPU.Build.0 = Release|Any CPU
{91A2AAFC-93D5-4215-AE11-8733AF1597B8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{91A2AAFC-93D5-4215-AE11-8733AF1597B8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{91A2AAFC-93D5-4215-AE11-8733AF1597B8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{91A2AAFC-93D5-4215-AE11-8733AF1597B8}.Release|Any CPU.Build.0 = Release|Any CPU
{1050A713-995F-4505-80D9-2E5DDB9F6769}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{1050A713-995F-4505-80D9-2E5DDB9F6769}.Debug|Any CPU.Build.0 = Debug|Any CPU
{1050A713-995F-4505-80D9-2E5DDB9F6769}.Release|Any CPU.ActiveCfg = Release|Any CPU
{1050A713-995F-4505-80D9-2E5DDB9F6769}.Release|Any CPU.Build.0 = Release|Any CPU
{09E0E9AD-EAFD-4A03-94D0-29C60FEC3547}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{09E0E9AD-EAFD-4A03-94D0-29C60FEC3547}.Debug|Any CPU.Build.0 = Debug|Any CPU
{09E0E9AD-EAFD-4A03-94D0-29C60FEC3547}.Release|Any CPU.ActiveCfg = Release|Any CPU
{09E0E9AD-EAFD-4A03-94D0-29C60FEC3547}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
Binary file added HDrezka.ico
Binary file not shown.
22 changes: 0 additions & 22 deletions HdrezkaMirrorConfigLauncher/App.config

This file was deleted.

Binary file added HdrezkaMirrorConfigLauncher/HDrezka.ico
Binary file not shown.
127 changes: 14 additions & 113 deletions HdrezkaMirrorConfigLauncher/HdrezkaMirrorConfigLauncher.csproj
Original file line number Diff line number Diff line change
@@ -1,122 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{57E755E4-B9BA-4771-B752-5F77CD2991B2}</ProjectGuid>
<OutputType>Exe</OutputType>
<RootNamespace>HdrezkaMirrorConfigLauncher</RootNamespace>
<AssemblyName>HdrezkaMirrorConfigLauncher</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic>
<IsWebBootstrapper>false</IsWebBootstrapper>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<ApplicationIcon>HDrezka.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>BECE6C5F35F3E51AD875A86A5BB593CA89312B69</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>HdrezkaMirrorConfigLauncher_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>true</GenerateManifests>
</PropertyGroup>
<PropertyGroup>
<SignManifests>true</SignManifests>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Extensions.Configuration, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Extensions.Configuration.8.0.0\lib\net462\Microsoft.Extensions.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration.Abstractions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Extensions.Configuration.Abstractions.8.0.0\lib\net462\Microsoft.Extensions.Configuration.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Primitives, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Extensions.Primitives.8.0.0\lib\net462\Microsoft.Extensions.Primitives.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Buffers, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll</HintPath>
</Reference>
<Reference Include="System.Core" />
<Reference Include="System.Memory, Version=4.0.1.2, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.Memory.4.5.5\lib\net461\System.Memory.dll</HintPath>
</Reference>
<Reference Include="System.Numerics.Vectors, Version=4.1.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll</HintPath>
</Reference>
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\System.Runtime.CompilerServices.Unsafe.6.0.0\lib\net461\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
</Reference>
<Reference Include="System.ValueTuple, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.ValueTuple.4.5.0\lib\net47\System.ValueTuple.dll</HintPath>
</Reference>
<Reference Include="YamlDotNet, Version=15.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>..\packages\YamlDotNet.15.1.2\lib\net47\YamlDotNet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>

<ItemGroup>
<None Include="App.config" />
<None Include="HdrezkaMirrorConfigLauncher_TemporaryKey.pfx" />
<None Include="packages.config" />
<Content Include="HDrezka.ico" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\HdrezkaMirrorSite\HdrezkaMirrorSite.csproj">
<Project>{9844558C-9965-4EBD-A4E3-78F9F2A8F3F7}</Project>
<Name>HdrezkaMirrorSite</Name>
</ProjectReference>
<PackageReference Include="YamlDotNet" Version="15.1.4" />
</ItemGroup>

<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.8 %28x86 и x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<ProjectReference Include="..\HdrezkaMirrorSite\HdrezkaMirrorSite.csproj" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<_LastSelectedProfileId>C:\Users\nikit\OneDrive\Рабочий стол\save\C#\HDRezkaMirror\HdrezkaMirrorConfigLauncher\Properties\PublishProfiles\FolderProfile1.pubxml</_LastSelectedProfileId>
</PropertyGroup>
</Project>
53 changes: 25 additions & 28 deletions HdrezkaMirrorConfigLauncher/Program.cs
Original file line number Diff line number Diff line change
@@ -1,33 +1,30 @@
using System.IO;
using HdrezkaMirrorSite;
using HdrezkaMirrorSite;
using YamlDotNet.RepresentationModel;

namespace HdrezkaMirrorConfigLauncher
YamlMappingNode yaml = ReadingYaml();

MirrorSiteOpener mirrorSiteOpener;

if (yaml["EmailIsSorted"].ToString() == "yes")
{
class Program
{
static void Main()
{
YamlMappingNode yaml = ReadingYaml();
if (yaml["EmailIsSorted"].ToString() == "yes")
{
new MirrorSiteOpener(yaml["Login"].ToString(), yaml["Password"].ToString());
}
else
{
new MirrorSiteOpenerUnsorted(yaml["Login"].ToString(), yaml["Password"].ToString());
}
}
mirrorSiteOpener = new(yaml["Login"].ToString(), yaml["Password"].ToString());
}
else
{
mirrorSiteOpener = new MirrorSiteOpenerUnsorted(yaml["Login"].ToString(), yaml["Password"].ToString());
}

await mirrorSiteOpener.Open();

static YamlMappingNode ReadingYaml()
{
using (StreamReader reader = new StreamReader("config.yml"))
{
YamlStream yaml = new YamlStream();
yaml.Load(reader);
YamlMappingNode root = (YamlMappingNode)yaml.Documents[0].RootNode;
return root;
}
}
}
await Task.Delay(1000);

Environment.Exit(0);

static YamlMappingNode ReadingYaml()
{
using StreamReader reader = new("config.yml");
YamlStream yaml = [];
yaml.Load(reader);
YamlMappingNode root = (YamlMappingNode)yaml.Documents[0].RootNode;
return root;
}
36 changes: 0 additions & 36 deletions HdrezkaMirrorConfigLauncher/Properties/AssemblyInfo.cs

This file was deleted.

4 changes: 0 additions & 4 deletions HdrezkaMirrorConfigLauncher/packages.config

This file was deleted.

Loading

0 comments on commit edee103

Please sign in to comment.