AutoTf.Logging 1.0.0-develop-20250331-1405

This is a prerelease version of AutoTf.Logging.
There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package AutoTf.Logging --version 1.0.0-develop-20250331-1405
                    
NuGet\Install-Package AutoTf.Logging -Version 1.0.0-develop-20250331-1405
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="AutoTf.Logging" Version="1.0.0-develop-20250331-1405" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="AutoTf.Logging" Version="1.0.0-develop-20250331-1405" />
                    
Directory.Packages.props
<PackageReference Include="AutoTf.Logging" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add AutoTf.Logging --version 1.0.0-develop-20250331-1405
                    
#r "nuget: AutoTf.Logging, 1.0.0-develop-20250331-1405"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package AutoTf.Logging@1.0.0-develop-20250331-1405
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=AutoTf.Logging&version=1.0.0-develop-20250331-1405&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=AutoTf.Logging&version=1.0.0-develop-20250331-1405&prerelease
                    
Install as a Cake Tool

AutoTF.Logging

A really really simple Logger that is used in several AutoTF Applications/Packages.

Logs to "/var/log/AutoTF/HostName/Date"

It's mainly based on Linux systems, but can run on Windows too without writing to any files.

To use it on windows, and still see logs from packages, set the "logToConsole" bool to true in the Logger ctor.

Using the logger

To use the logger, you just have to initialize it, and use it using it's Log method.

private Logger _logger = new Logger(logToConsole: false);
_logger.Log("Hello world");
Redirecting logs

To redirect logs and use them yourself too, you can hook yourself onto the NewLog event.

_logger.NewLog += NewLog;

private void NewLog(string obj)
{
    Console.WriteLine(obj);
}

Info & Contributions

Further documentation can be seen in AutoTF-Rail/AutoTf-Documentation

Would you like to contribute to this project, or noticed something wrong?

Feel free to contact us at opensource@autotf.de

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.