Skip to content

Commit 52dab38

Browse files
committed
✨ console project for testing
1 parent 01404f2 commit 52dab38

3 files changed

Lines changed: 42 additions & 0 deletions

File tree

Console/Console.csproj

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<OutputType>Exe</OutputType>
5+
<TargetFramework>net10.0</TargetFramework>
6+
<ImplicitUsings>enable</ImplicitUsings>
7+
<Nullable>enable</Nullable>
8+
</PropertyGroup>
9+
10+
<ItemGroup>
11+
<ProjectReference Include="..\EliteAPI\EliteAPI.csproj" />
12+
</ItemGroup>
13+
</Project>

Console/Program.cs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
using EliteApi;
2+
using EliteAPI.Json;
3+
4+
var api = new EliteDangerousApi();
5+
api.OnJournalEvent(e =>
6+
{
7+
var eventName = JsonUtils.GetEventName(e);
8+
var paths = JsonUtils.FlattenJson(e).Select(p => p.WithPath($"EliteAPI.{eventName}.{p.Path}")).ToList();
9+
foreach (var path in paths)
10+
{
11+
Console.WriteLine($"{path.Path}: {path.Value} ({path.Type})");
12+
}
13+
});
14+
15+
Thread.Sleep(-1);

EliteAPI.sln

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EliteVA", "EliteVA\EliteVA.
1111
EndProject
1212
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VoiceAttack", "VoiceAttack\VoiceAttack.csproj", "{A30596CE-C88C-412C-9AAE-8FA6927BB9EF}"
1313
EndProject
14+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Console", "Console\Console.csproj", "{272A8615-5B48-40A8-A349-771127F856D4}"
15+
EndProject
1416
Global
1517
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1618
Debug|Any CPU = Debug|Any CPU
@@ -69,6 +71,18 @@ Global
6971
{A30596CE-C88C-412C-9AAE-8FA6927BB9EF}.Release|x64.Build.0 = Release|Any CPU
7072
{A30596CE-C88C-412C-9AAE-8FA6927BB9EF}.Release|x86.ActiveCfg = Release|Any CPU
7173
{A30596CE-C88C-412C-9AAE-8FA6927BB9EF}.Release|x86.Build.0 = Release|Any CPU
74+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
75+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|Any CPU.Build.0 = Debug|Any CPU
76+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|x64.ActiveCfg = Debug|Any CPU
77+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|x64.Build.0 = Debug|Any CPU
78+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|x86.ActiveCfg = Debug|Any CPU
79+
{272A8615-5B48-40A8-A349-771127F856D4}.Debug|x86.Build.0 = Debug|Any CPU
80+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|Any CPU.ActiveCfg = Release|Any CPU
81+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|Any CPU.Build.0 = Release|Any CPU
82+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|x64.ActiveCfg = Release|Any CPU
83+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|x64.Build.0 = Release|Any CPU
84+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|x86.ActiveCfg = Release|Any CPU
85+
{272A8615-5B48-40A8-A349-771127F856D4}.Release|x86.Build.0 = Release|Any CPU
7286
EndGlobalSection
7387
GlobalSection(SolutionProperties) = preSolution
7488
HideSolutionNode = FALSE

0 commit comments

Comments
 (0)