From b980dd99f58c34f0b36c2c10cf5ec4885b758208 Mon Sep 17 00:00:00 2001 From: PratyushKing <83279568+PratyushKing@users.noreply.github.com> Date: Tue, 5 Dec 2023 19:36:28 +0530 Subject: [PATCH 1/3] some changes --- Build/VMWare/Workstation/Filesystem.vmdk | Bin 393216 -> 393216 bytes .../packages.lock.json | 14 +++++++++ source/Cosmos.Build.Tasks/packages.lock.json | 14 +++++++++ .../.template.config/template.json | 13 ++++++++ .../csharp-linux/CSharpProject.csproj | 28 ++++++++++++++++++ source/templates/csharp-linux/Kernel.cs | 24 +++++++++++++++ source/templates/csharp/CSharpProject.csproj | 1 - source/templates/csharp/CSharpProject.sln | 17 +++++++++++ 8 files changed, 110 insertions(+), 1 deletion(-) create mode 100644 source/templates/csharp-linux/.template.config/template.json create mode 100644 source/templates/csharp-linux/CSharpProject.csproj create mode 100644 source/templates/csharp-linux/Kernel.cs create mode 100644 source/templates/csharp/CSharpProject.sln diff --git a/Build/VMWare/Workstation/Filesystem.vmdk b/Build/VMWare/Workstation/Filesystem.vmdk index 0d95353311b8fc2ba9b64847554f8ca11e7b69e3..d458cc141f7b1fd237ac2e3aea886633d87f8dc2 100644 GIT binary patch delta 168 zcmZo@kZ5R-*kHpXZD3)XW|VB4!c~x1l$uxK?CD~g1_hIInW}^mQxXeGQj0<=3sMzq z6_helQYRNM#~9}1=cPO6=am4pc)EZjOi~OIQ<6+mOpGjnC^a?3z{DiUDA59D{$yij zXYsPkqLR|Y9FOp@)S}|d{5+6GOC_$&51HlFCMJkCX|-uFwrMf7X)(8Hu`JVKy#@gG C*EIqF delta 156 zcmZo@kZ5R-*kHqCXpxj;X=!3^$yJb8l$uxK?CD~g1_fN1#eRt;nPsWLd5HzZ8Tlo) zN_qK8lf#*+CU0gIH%&=N(#y%uOLxxCD*@{CbWyNXP%<>JFf&g|PBln0FicJ~GPf`` vvamEYhFdeafZ2KSOQx{N7nwvhUu0HLYtm}dVr + + + net6.0 + cosmos + false + True + + + + False + False + Pipe: Cosmos\Serial + Serial: COM1 + VMware + VMware + Use VMware Player or Workstation to deploy and debug. + 192.168.0.8 + + + + + + + + + + diff --git a/source/templates/csharp-linux/Kernel.cs b/source/templates/csharp-linux/Kernel.cs new file mode 100644 index 0000000000..dabb369ae0 --- /dev/null +++ b/source/templates/csharp-linux/Kernel.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.Text; +using Sys = Cosmos.System; + +namespace $safeprojectname$ +{ + public class Kernel: Sys.Kernel + { + + protected override void BeforeRun() + { + Console.WriteLine("Cosmos booted successfully. Type a line of text to get it echoed back."); + } + + protected override void Run() + { + Console.Write("Input: "); + var input = Console.ReadLine(); + Console.Write("Text typed: "); + Console.WriteLine(input); + } + } +} diff --git a/source/templates/csharp/CSharpProject.csproj b/source/templates/csharp/CSharpProject.csproj index c4e66da201..86947e3838 100644 --- a/source/templates/csharp/CSharpProject.csproj +++ b/source/templates/csharp/CSharpProject.csproj @@ -8,7 +8,6 @@ - false False False Pipe: Cosmos\Serial diff --git a/source/templates/csharp/CSharpProject.sln b/source/templates/csharp/CSharpProject.sln new file mode 100644 index 0000000000..6b92389db0 --- /dev/null +++ b/source/templates/csharp/CSharpProject.sln @@ -0,0 +1,17 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CSharpProject", "CSharpProject.csproj", "{DE2AFF01-488B-4B4F-98F4-D70F7C6F5FA1}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {DE2AFF01-488B-4B4F-98F4-D70F7C6F5FA1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DE2AFF01-488B-4B4F-98F4-D70F7C6F5FA1}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DE2AFF01-488B-4B4F-98F4-D70F7C6F5FA1}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DE2AFF01-488B-4B4F-98F4-D70F7C6F5FA1}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection +EndGlobal From b582425c92b24e40440c5c87e24b70c70264fec1 Mon Sep 17 00:00:00 2001 From: PratyushKing <83279568+PratyushKing@users.noreply.github.com> Date: Tue, 5 Dec 2023 19:41:23 +0530 Subject: [PATCH 2/3] template changes --- Docs/articles/Installation/DevKit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Docs/articles/Installation/DevKit.md b/Docs/articles/Installation/DevKit.md index 800c047387..362b170f4a 100644 --- a/Docs/articles/Installation/DevKit.md +++ b/Docs/articles/Installation/DevKit.md @@ -26,6 +26,6 @@ Run `make` to build Cosmos. Cosmos will clone all the required repos, build itself, and install it and it's nuget packages to the system automatically. ### dotnet Project Templates -If you are using linux or prefer not using Visual Studio for your projects, you can install the dotnet project template using `dotnet new --install ./source/templates/csharp/` assuming you are currently in the Cosmos base directory. +If you are using linux or prefer not using Visual Studio for your projects, you can install the dotnet project template using `dotnet new --install ./source/templates/csharp-linux/` assuming you are currently in the Cosmos base directory. After installing the template use `dotnet new cosmosCSKernel -n {name}` to create a new Cosmos Kernel project. -The dotnet template can be removed at a later time using `dotnet new --uninstall ./source/templates/csharp/`. +The dotnet template can be removed later on using `dotnet new --uninstall ./source/templates/csharp-linux/`. From 7d9631d42a01247e8b917ba6ee3215f7fffdd6c7 Mon Sep 17 00:00:00 2001 From: PratyushKing <83279568+PratyushKing@users.noreply.github.com> Date: Tue, 5 Dec 2023 19:45:17 +0530 Subject: [PATCH 3/3] template change --- source/templates/csharp-linux/CSharpProject.csproj | 1 + 1 file changed, 1 insertion(+) diff --git a/source/templates/csharp-linux/CSharpProject.csproj b/source/templates/csharp-linux/CSharpProject.csproj index 86947e3838..c4e66da201 100644 --- a/source/templates/csharp-linux/CSharpProject.csproj +++ b/source/templates/csharp-linux/CSharpProject.csproj @@ -8,6 +8,7 @@ + false False False Pipe: Cosmos\Serial