Revert "Add new auto-update C# program"

This reverts commit 6c280ac0ed.
This commit is contained in:
Adison Cavani 2021-10-09 18:41:43 +02:00
parent 6c280ac0ed
commit cc1b94b8b4
No known key found for this signature in database
GPG key ID: 2C36C61283E73DC9
30 changed files with 0 additions and 548 deletions

Binary file not shown.

View file

@ -1,15 +0,0 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<Authors>Adison Cavani</Authors>
<Company>Adison Cavani</Company>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="CommandLineParser" Version="2.8.0" />
<PackageReference Include="SharpZipLib" Version="1.3.3" />
</ItemGroup>
</Project>

View file

@ -1,25 +0,0 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31717.71
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DistroGrubThemes", "DistroGrubThemes.csproj", "{0CCFA519-E529-4AF9-B800-92FC96351EE9}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{0CCFA519-E529-4AF9-B800-92FC96351EE9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0CCFA519-E529-4AF9-B800-92FC96351EE9}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0CCFA519-E529-4AF9-B800-92FC96351EE9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0CCFA519-E529-4AF9-B800-92FC96351EE9}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {C18C7214-AE56-46A5-8C62-8A5A2B8886D7}
EndGlobalSection
EndGlobal

View file

@ -1,117 +0,0 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using CommandLine;
namespace DistroGrubThemes
{
internal class Program
{
string repoPath = string.Empty;
string iconsPath = string.Empty;
string customizePath = string.Empty;
string fontsPath = string.Empty;
static void Main(string[] args)
{
Parser.Default.ParseArguments<ProgramOptions>(args).WithParsed(RunOptions).WithNotParsed(HandleParseError);
}
static void RunOptions(ProgramOptions opts)
{
Program program = new Program();
if (string.IsNullOrWhiteSpace(opts.ArchivedFiles))
{
program.UpdateAssets();
}
else if(opts.ArchivedFiles == "all")
{
Console.WriteLine("Correct");
}
else
{
Console.WriteLine("DistroGrubThemes 1.0.0");
Console.WriteLine("Copyright (C) 2021 Adison Cavani\n");
Console.WriteLine("ERROR(S): ");
Console.WriteLine($" Argument {opts.ArchivedFiles} is unknown.");
Console.WriteLine("\n -a, --archive\tTest\n");
}
}
static void HandleParseError(IEnumerable<Error> errs)
{
Environment.Exit(1);
}
void UpdateAssets()
{
Console.Write("Repository path: ");
CheckRepoPath(Console.ReadLine());
iconsPath = repoPath + @"\assets\icons";
customizePath = repoPath + @"\customize";
fontsPath = repoPath + @"\font";
UpdateIcons();
UpdateFonts();
}
void UpdateIcons()
{
var icons = FilesArray(iconsPath);
foreach (var directory in CustomDirectories())
{
foreach (var icon in icons)
{
File.Copy(iconsPath + @"\" + icon, directory + @"\icons\" + icon, true);
}
}
}
void UpdateFonts()
{
var fonts = FilesArray(fontsPath);
foreach (var directory in CustomDirectories())
{
foreach (var font in fonts)
{
File.Copy(fontsPath + @"\" + font, directory + @"\" + font, true);
}
}
}
List<string> FilesArray(string folderPath)
{
return new List<string>(Directory.GetFiles(folderPath).Select(Path.GetFileName));
}
string[] CustomDirectories()
{
return Directory.GetDirectories(customizePath);
}
void CheckRepoPath(string path)
{
if (Directory.Exists(path) && path.Contains("distro-grub-themes"))
{
int index = path.IndexOf("distro-grub-themes") + 18;
repoPath = path.Substring(0, index);
}
else
{
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine("ERROR: Could not find repository in this path!");
Console.ResetColor();
Environment.Exit(1);
}
}
}
}

View file

@ -1,10 +0,0 @@
using CommandLine;
namespace DistroGrubThemes
{
public class ProgramOptions
{
[Option('a', "archive", HelpText = "Create theme archive.")]
public string ArchivedFiles { get; set; }
}
}

View file

@ -1,57 +0,0 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v3.1",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v3.1": {
"DistroGrubThemes/1.0.0": {
"dependencies": {
"CommandLineParser": "2.8.0",
"SharpZipLib": "1.3.3"
},
"runtime": {
"DistroGrubThemes.dll": {}
}
},
"CommandLineParser/2.8.0": {
"runtime": {
"lib/netstandard2.0/CommandLine.dll": {
"assemblyVersion": "2.8.0.0",
"fileVersion": "2.8.0.0"
}
}
},
"SharpZipLib/1.3.3": {
"runtime": {
"lib/netstandard2.1/ICSharpCode.SharpZipLib.dll": {
"assemblyVersion": "1.3.3.11",
"fileVersion": "1.3.3.11"
}
}
}
}
},
"libraries": {
"DistroGrubThemes/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"CommandLineParser/2.8.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-eco2HlKQBY4Joz9odHigzGpVzv6pjsXnY5lziioMveQxr+i2Z7xYcIOMeZTgYiqnMtMAbXMXsVhrNfWO5vJS8Q==",
"path": "commandlineparser/2.8.0",
"hashPath": "commandlineparser.2.8.0.nupkg.sha512"
},
"SharpZipLib/1.3.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-N8+hwhsKZm25tDJfWpBSW7EGhH/R7EMuiX+KJ4C4u+fCWVc1lJ5zg1u3S1RPPVYgTqhx/C3hxrqUpi6RwK5+Tg==",
"path": "sharpziplib/1.3.3",
"hashPath": "sharpziplib.1.3.3.nupkg.sha512"
}
}
}

View file

@ -1,8 +0,0 @@
{
"runtimeOptions": {
"additionalProbingPaths": [
"C:\\Users\\Adison\\.dotnet\\store\\|arch|\\|tfm|",
"C:\\Users\\Adison\\.nuget\\packages"
]
}
}

View file

@ -1,9 +0,0 @@
{
"runtimeOptions": {
"tfm": "netcoreapp3.1",
"framework": {
"name": "Microsoft.NETCore.App",
"version": "3.1.0"
}
}
}

View file

@ -1,4 +0,0 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v3.1", FrameworkDisplayName = "")]

View file

@ -1,23 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("Adison Cavani")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("DistroGrubThemes")]
[assembly: System.Reflection.AssemblyTitleAttribute("DistroGrubThemes")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Generated by the MSBuild WriteCodeFragment class.

View file

@ -1 +0,0 @@
2e7069c1fe1d700ebb15efbd6263f365c01481f0

View file

@ -1,3 +0,0 @@
is_global = true
build_property.RootNamespace = DistroGrubThemes
build_property.ProjectDir = C:\Users\Adison\repos\distro-grub-themes\src\

View file

@ -1 +0,0 @@
6549facf873ee6885456dcfdc5d92e8b8e5709e4

View file

@ -1,31 +0,0 @@
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.exe
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.deps.json
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.runtimeconfig.json
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.runtimeconfig.dev.json
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.dll
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\DistroGrubThemes.pdb
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.csproj.AssemblyReference.cache
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.GeneratedMSBuildEditorConfig.editorconfig
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.AssemblyInfoInputs.cache
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.AssemblyInfo.cs
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.csproj.CoreCompileInputs.cache
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.dll
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.pdb
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\obj\Debug\netcoreapp3.1\DistroGrubThemes.genruntimeconfig.cache
C:\Users\Adison\repos\distro-grub-themes\src\DistroGrubThemes\bin\Debug\netcoreapp3.1\CommandLine.dll
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.exe
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.deps.json
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.runtimeconfig.json
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.runtimeconfig.dev.json
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.dll
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\DistroGrubThemes.pdb
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\CommandLine.dll
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.csproj.AssemblyReference.cache
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.GeneratedMSBuildEditorConfig.editorconfig
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.AssemblyInfoInputs.cache
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.AssemblyInfo.cs
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.csproj.CoreCompileInputs.cache
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.dll
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.pdb
C:\Users\Adison\repos\distro-grub-themes\src\obj\Debug\netcoreapp3.1\DistroGrubThemes.genruntimeconfig.cache
C:\Users\Adison\repos\distro-grub-themes\src\bin\Debug\netcoreapp3.1\ICSharpCode.SharpZipLib.dll

View file

@ -1 +0,0 @@
f800a8d40bdfdb9aae9123a1d76281adf32f7de0

View file

@ -1,72 +0,0 @@
{
"format": 1,
"restore": {
"C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj": {}
},
"projects": {
"C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj",
"projectName": "DistroGrubThemes",
"projectPath": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj",
"packagesPath": "C:\\Users\\Adison\\.nuget\\packages\\",
"outputPath": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\Adison\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"netcoreapp3.1"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"dependencies": {
"CommandLineParser": {
"target": "Package",
"version": "[2.8.0, )"
},
"SharpZipLib": {
"target": "Package",
"version": "[1.3.3, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.100-rc.1.21463.6\\RuntimeIdentifierGraph.json"
}
}
}
}
}

View file

@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\Adison\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.0.0</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\Adison\.nuget\packages\" />
</ItemGroup>
</Project>

View file

@ -1,2 +0,0 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />

View file

@ -1,143 +0,0 @@
{
"version": 3,
"targets": {
".NETCoreApp,Version=v3.1": {
"CommandLineParser/2.8.0": {
"type": "package",
"compile": {
"lib/netstandard2.0/CommandLine.dll": {}
},
"runtime": {
"lib/netstandard2.0/CommandLine.dll": {}
}
},
"SharpZipLib/1.3.3": {
"type": "package",
"compile": {
"lib/netstandard2.1/ICSharpCode.SharpZipLib.dll": {}
},
"runtime": {
"lib/netstandard2.1/ICSharpCode.SharpZipLib.dll": {}
}
}
}
},
"libraries": {
"CommandLineParser/2.8.0": {
"sha512": "eco2HlKQBY4Joz9odHigzGpVzv6pjsXnY5lziioMveQxr+i2Z7xYcIOMeZTgYiqnMtMAbXMXsVhrNfWO5vJS8Q==",
"type": "package",
"path": "commandlineparser/2.8.0",
"files": [
".nupkg.metadata",
".signature.p7s",
"CommandLine20.png",
"License.md",
"README.md",
"commandlineparser.2.8.0.nupkg.sha512",
"commandlineparser.nuspec",
"lib/net40/CommandLine.dll",
"lib/net40/CommandLine.xml",
"lib/net45/CommandLine.dll",
"lib/net45/CommandLine.xml",
"lib/net461/CommandLine.dll",
"lib/net461/CommandLine.xml",
"lib/netstandard2.0/CommandLine.dll",
"lib/netstandard2.0/CommandLine.xml"
]
},
"SharpZipLib/1.3.3": {
"sha512": "N8+hwhsKZm25tDJfWpBSW7EGhH/R7EMuiX+KJ4C4u+fCWVc1lJ5zg1u3S1RPPVYgTqhx/C3hxrqUpi6RwK5+Tg==",
"type": "package",
"path": "sharpziplib/1.3.3",
"files": [
".nupkg.metadata",
".signature.p7s",
"images/sharpziplib-nuget-256x256.png",
"lib/net45/ICSharpCode.SharpZipLib.dll",
"lib/net45/ICSharpCode.SharpZipLib.pdb",
"lib/net45/ICSharpCode.SharpZipLib.xml",
"lib/netstandard2.0/ICSharpCode.SharpZipLib.dll",
"lib/netstandard2.0/ICSharpCode.SharpZipLib.pdb",
"lib/netstandard2.0/ICSharpCode.SharpZipLib.xml",
"lib/netstandard2.1/ICSharpCode.SharpZipLib.dll",
"lib/netstandard2.1/ICSharpCode.SharpZipLib.pdb",
"lib/netstandard2.1/ICSharpCode.SharpZipLib.xml",
"sharpziplib.1.3.3.nupkg.sha512",
"sharpziplib.nuspec"
]
}
},
"projectFileDependencyGroups": {
".NETCoreApp,Version=v3.1": [
"CommandLineParser >= 2.8.0",
"SharpZipLib >= 1.3.3"
]
},
"packageFolders": {
"C:\\Users\\Adison\\.nuget\\packages\\": {}
},
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj",
"projectName": "DistroGrubThemes",
"projectPath": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj",
"packagesPath": "C:\\Users\\Adison\\.nuget\\packages\\",
"outputPath": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\Adison\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"netcoreapp3.1"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"netcoreapp3.1": {
"targetAlias": "netcoreapp3.1",
"dependencies": {
"CommandLineParser": {
"target": "Package",
"version": "[2.8.0, )"
},
"SharpZipLib": {
"target": "Package",
"version": "[1.3.3, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.100-rc.1.21463.6\\RuntimeIdentifierGraph.json"
}
}
}
}

View file

@ -1,11 +0,0 @@
{
"version": 2,
"dgSpecHash": "EFQj79zBatn2G/DjQrKpneAgO4U+UyxjBu8g0xxI6D4mt9u9ST/y4DY1pldywB4ZlulDJUCwCsydRgspdpt8/Q==",
"success": true,
"projectFilePath": "C:\\Users\\Adison\\repos\\distro-grub-themes\\src\\DistroGrubThemes.csproj",
"expectedPackageFiles": [
"C:\\Users\\Adison\\.nuget\\packages\\commandlineparser\\2.8.0\\commandlineparser.2.8.0.nupkg.sha512",
"C:\\Users\\Adison\\.nuget\\packages\\sharpziplib\\1.3.3\\sharpziplib.1.3.3.nupkg.sha512"
],
"logs": []
}