chore: setup for day 9

This commit is contained in:
Stevan Freeborn
2024-12-08 23:18:17 -06:00
parent 840306855f
commit 0d940a8812
5 changed files with 84 additions and 1 deletions
+4 -1
View File
@@ -1,5 +1,8 @@
{
"editor.formatOnSave": true,
"dotnet.defaultSolution": "../AdventOfCode2024.sln",
"dotnet.testWindow.useTestingPlatformProtocol": true
"dotnet.testWindow.useTestingPlatformProtocol": true,
"cSpell.words": [
"Fragmenter"
]
}
@@ -0,0 +1,19 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<NoWarn>CA1822</NoWarn>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\DiskFragmenter\DiskFragmenter.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="TUnit" Version="0.4.86" />
</ItemGroup>
</Project>
+21
View File
@@ -0,0 +1,21 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<NoWarn>CA1822</NoWarn>
</PropertyGroup>
<ItemGroup>
<InternalsVisibleTo Include="$(AssemblyName).Tests" />
</ItemGroup>
<ItemGroup>
<Content Include="..\INPUT.txt">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
</ItemGroup>
</Project>
+24
View File
@@ -0,0 +1,24 @@
using System.Diagnostics;
if (args.Length is 0)
{
Console.WriteLine("Please provide a path to the input file.");
return;
}
if (File.Exists(args[0]) is false)
{
Console.WriteLine("The provided file does not exist.");
return;
}
var isPart2 = args.Length is 2 && args[1] is "part2";
var input = await File.ReadAllLinesAsync(args[0]);
var stopwatch = new Stopwatch();
stopwatch.Start();
// TODO: Implement solution
stopwatch.Stop();
Console.WriteLine($". ({stopwatch.ElapsedMilliseconds}ms)");
+16
View File
@@ -66,6 +66,12 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ResonantCollinearity", "08\
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ResonantCollinearity.Tests", "08\ResonantCollinearity.Tests\ResonantCollinearity.Tests.csproj", "{4741807B-CD85-4A87-BE6E-DC506C4CD1E6}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "09", "09", "{2971DA3F-AD59-4BE1-A860-4F1B60BCB771}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DiskFragmenter", "09\DiskFragmenter\DiskFragmenter.csproj", "{EDD2A424-2BD0-408F-A32D-E5AE3316B68E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DiskFragmenter.Tests", "09\DiskFragmenter.Tests\DiskFragmenter.Tests.csproj", "{9A7AAC2C-A23B-4FFE-8B2B-93E204904866}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -139,6 +145,14 @@ Global
{4741807B-CD85-4A87-BE6E-DC506C4CD1E6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4741807B-CD85-4A87-BE6E-DC506C4CD1E6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4741807B-CD85-4A87-BE6E-DC506C4CD1E6}.Release|Any CPU.Build.0 = Release|Any CPU
{EDD2A424-2BD0-408F-A32D-E5AE3316B68E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{EDD2A424-2BD0-408F-A32D-E5AE3316B68E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EDD2A424-2BD0-408F-A32D-E5AE3316B68E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{EDD2A424-2BD0-408F-A32D-E5AE3316B68E}.Release|Any CPU.Build.0 = Release|Any CPU
{9A7AAC2C-A23B-4FFE-8B2B-93E204904866}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9A7AAC2C-A23B-4FFE-8B2B-93E204904866}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9A7AAC2C-A23B-4FFE-8B2B-93E204904866}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9A7AAC2C-A23B-4FFE-8B2B-93E204904866}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{1AFE2FF1-A55D-4D86-A9BB-9875CA0D14D8} = {270B7829-6D23-4B34-91FE-D87D533AF2AB}
@@ -157,5 +171,7 @@ Global
{23C9756E-F2F4-44CA-B38A-DB92782D7858} = {73EE2FA2-6417-4518-9790-72D4F2B62CAF}
{425DF10B-4621-4882-935A-0320F1C4B6DD} = {F2A51E88-BCCC-4778-9369-63E72D052554}
{4741807B-CD85-4A87-BE6E-DC506C4CD1E6} = {F2A51E88-BCCC-4778-9369-63E72D052554}
{EDD2A424-2BD0-408F-A32D-E5AE3316B68E} = {2971DA3F-AD59-4BE1-A860-4F1B60BCB771}
{9A7AAC2C-A23B-4FFE-8B2B-93E204904866} = {2971DA3F-AD59-4BE1-A860-4F1B60BCB771}
EndGlobalSection
EndGlobal