-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
23 changed files
with
312 additions
and
620 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
127 changes: 14 additions & 113 deletions
127
HdrezkaMirrorConfigLauncher/HdrezkaMirrorConfigLauncher.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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> |
6 changes: 6 additions & 0 deletions
6
HdrezkaMirrorConfigLauncher/HdrezkaMirrorConfigLauncher.csproj.user
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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; | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.