Using Zeus with C# .Net Core

Find Tips and tricks on how to better use the Zeus IDE. Feel free to post your own tips but please do not post bug reports, feature requests or questions here.
Post Reply
jussij
Site Admin
Posts: 2496
Joined: Fri Aug 13, 2004 5:10 pm

Using Zeus with C# .Net Core

Post by jussij »

Installation
1. Download .Net Core SDK from here: https://dotnet.microsoft.com/download/dotnet-core

In this example the Windows x64 version of the SDK 5.0.102 was downloaded and installed.
net-core.png
net-core.png (121.88 KiB) Viewed 2709 times
2. After running the installer start the Zeus IDE and check the installation by using the Tools, DOS Command Line menu to run the following command:

Code: Select all

dotnet --info
Running that command should result in the following output:
.NET SDK (reflecting any global.json):
Version: 5.0.102
Commit: 71365b4d42

Runtime Environment:
OS Name: Windows
OS Version: 10.0.19042
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\5.0.102\
...
Creating a Test Project

1. Using the Tools, Language Shells, Command Prompt menu to open up a command prompt.

2. Navigate to the directory in which the new project will be created, for example:

Code: Select all

C:\>md \Projects
C:\>cd \Projects
3. Run this new command to create a new console application:

Code: Select all

dotnet new console -o TestConsole
NOTE: To create different types of projects (i.e. WinForms, ASP.Net etc.) refer to the different new command options found here.

This new command should result in the following output:
Welcome to .NET 5.0!
---------------------
SDK Version: 5.0.102

Telemetry
---------
The .NET tools collect usage data in order to help us improve your experience. It is collected by Microsoft and shared with the community. You can opt-out of telemetry by setting the DOTNET_CLI_TELEMETRY_OPTOUT environment variable to '1' or 'true' using your favorite shell.

Read more about .NET CLI Tools telemetry: https://aka.ms/dotnet-cli-telemetry

----------------
Installed an ASP.NET Core HTTPS development certificate.
To trust the certificate run 'dotnet dev-certs https --trust' (Windows and macOS only).
Learn about HTTPS: https://aka.ms/dotnet-https
----------------
Write your first app: https://aka.ms/dotnet-hello-world
Find out what's new: https://aka.ms/dotnet-whats-new
Explore documentation: https://aka.ms/dotnet-docs
Report issues and find source on GitHub: https://github.com/dotnet/core
Use 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli
--------------------------------------------------------------------------------------
Getting ready...
The template "Console Application" was created successfully.

Processing post-creation actions...
Running 'dotnet restore' on TestConsole\TestConsole.csproj...
Determining projects to restore...
Restored C:\Projects\TestConsole\TestConsole.csproj (in 42 ms).
Restore succeeded.
This should have created a new project folder as shown below:

Code: Select all

C:\Projects>dir
 Volume in drive C is Windows
 Volume Serial Number is 3690-9A91

 Directory of C:\Projects

19/01/2021  12:01 PM    <DIR>          .
19/01/2021  12:01 PM    <DIR>          ..
19/01/2021  12:01 PM    <DIR>          TestConsole
               0 File(s)              0 bytes
               3 Dir(s)  128,789,917,696 bytes free
Building the TestConsole Project

1. Using the same Zeus IDE command shell, build the project use the following commands:

Code: Select all

cd \Projects\TestConsole
dotnet build
This should result in the following output:
Microsoft (R) Build Engine version 16.8.3+39993bd9d for .NET
Copyright (C) Microsoft Corporation. All rights reserved.

Determining projects to restore...
All projects are up-to-date for restore.
TestConsole -> C:\projects\TestConsole\bin\Debug\net5.0\TestConsole.dll

Build succeeded.
0 Warning(s)
0 Error(s)

Time Elapsed 00:00:01.42
2. To run the resulting TestConsole.dll file using the following command:

Code: Select all

dotnet run
This should result in the following output:
Hello World!
Creating a Zeus Workspace
As described here a Zeus Workspace can be used to help manage the code base.

To create a workspace do the following:
  • Use the Zeus Workspace, Import menu.
  • In the resulting file open dialog select the *.csproj filter.
  • Select the TestConsole.csproj
These steps will create Zeus workspace for that .Net Core project:

Setting up the C# Language Server
To setup the C# language server follow the instructions found here: https://www.zeusedit.com/lsp/cs-dls.html

Zeus will use the C# language server for code completion, code navigation and tooltip information.
net-lsp.png
net-lsp.png (173.76 KiB) Viewed 2709 times
Cheers Jussi
Post Reply