{"id":22835220,"url":"https://github.com/jchristn/loggingmodule","last_synced_at":"2025-04-05T08:06:32.532Z","repository":{"id":38185403,"uuid":"66210948","full_name":"jchristn/LoggingModule","owner":"jchristn","description":"Brain-dead easy C# class library for logging to syslog, console, and file","archived":false,"fork":false,"pushed_at":"2025-01-07T15:40:06.000Z","size":7275,"stargazers_count":30,"open_issues_count":2,"forks_count":9,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-29T07:06:15.979Z","etag":null,"topics":["console","debug","info","log","logging","syslog","warn"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jchristn.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["jchristn"],"custom":["https://paypal.me/joelchristner"]}},"created_at":"2016-08-21T17:19:10.000Z","updated_at":"2025-01-07T15:40:41.000Z","dependencies_parsed_at":"2025-01-17T03:06:08.001Z","dependency_job_id":"65694a8a-94f0-4a9d-ad26-73eb035238f4","html_url":"https://github.com/jchristn/LoggingModule","commit_stats":{"total_commits":53,"total_committers":2,"mean_commits":26.5,"dds":"0.018867924528301883","last_synced_commit":"62278694c0ac17b79e7d6a570b976f9d60d5e0c2"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jchristn%2FLoggingModule","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jchristn%2FLoggingModule/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jchristn%2FLoggingModule/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jchristn%2FLoggingModule/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jchristn","download_url":"https://codeload.github.com/jchristn/LoggingModule/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247305933,"owners_count":20917208,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["console","debug","info","log","logging","syslog","warn"],"created_at":"2024-12-12T22:08:44.435Z","updated_at":"2025-04-05T08:06:32.504Z","avatar_url":"https://github.com/jchristn.png","language":"C#","readme":"# SyslogLogging\n\n[![NuGet Version](https://img.shields.io/nuget/v/SyslogLogging.svg?style=flat)](https://www.nuget.org/packages/SyslogLogging/) [![NuGet](https://img.shields.io/nuget/dt/SyslogLogging.svg)](https://www.nuget.org/packages/SyslogLogging) \n\nSimple C# class library for logging to syslog, console, and file, targeted to .NET Core, .NET Standard, and .NET Framework.  For a sample app please refer to the included test project.\n\nSyslogLogging is targeted to .NET Core, .NET Standard, and .NET Framework.\n\n## Help or Feedback\n\nFirst things first - do you need help or have feedback?  File an issue here!  We'd love to hear from you.\n\n## New in v2.0.x\n\n- Breaking changes including new constructors and minor API changes\n- Support for multiple syslog servers\n- Simplified class definitions\n\n## It's Really Easy...  I Mean, REALLY Easy\n\n### Easiest Way Possible\n\nUsing the constructor with no parameters will cause the library to log to `127.0.0.1:514`.\n\n```csharp\nusing SyslogLogging;\nLoggingModule log = new LoggingModule();\nlog.Debug(\"Hello, world!\");\n```\n\n### Single Syslog Server\n\n```csharp\nusing SyslogLogging;\n\nLoggingModule log = new LoggingModule(\"mysyslogserver\", 514);\nlog.Debug(\"Hello, world!\");\n```\n\n### Multiple Syslog Servers and Console\n\n```csharp\nusing SyslogLogging;\n\nList\u003cSyslogServer\u003e servers = new List\u003cSyslogServer\u003e\n{\n  new SyslogServer(\"logginghost.com\", 2000),\n  new SyslogServer(\"myhost.com\", 514)\n};\n\nLoggingModule log = new LoggingModule(servers, true); // true to enable console\nlog.Warn(\"Look out!\");\n```\n\n### Logging to File\n\n```csharp\nusing SyslogLogging;\n\nLoggingModule log = new LoggingModule(\"mylogfile.txt\");\nlog.Info(\"Here's some new information!\");\n```\n\n### Logging EVERYWHERE\n\n```csharp\nusing SyslogLogging;\n\nList\u003cSyslogServer\u003e servers = new List\u003cSyslogServer\u003e\n{\n  new SyslogServer(\"127.0.0.1\", 514)\n};\n\nLoggingModule log = new LoggingModule(servers, true); // true to enable console\nlog.Settings.FileLogging = FileLoggingMode.SingleLogFile;\nlog.Settings.LogFilename = \"mylogfile.txt\";\nlog.Alert(\"We're going everywhere!\");\n```\n\nWhen using `FileLoggingMode.FileWithDate`, LoggingModule with append `.yyyyMMdd to the supplied filename in `LogFilename.  When using `FileLoggingMode.SingleLogFile`, the filename is left untouched.\n\n## Changing Console Message Color\n\nColors are disabled by default to ensure compatibility across different operating systems and environments.\n\nIf you wish to enable colors and change the colors used by the library, set `Settings.EnableColors` to `true` and modify the `Settings.Colors` property.  A variable of type `ColorScheme` exists for each severity level.  To disable colors, set `Settings.EnableColors` to false.\n\n```csharp\nlog.Settings.EnableColors = true;\nlog.Settings.Colors.Debug = new ColorScheme(ConsoleColor.DarkGray, ConsoleColor.Black);\n```\n\n## Special Thanks\n\nWe'd like to extend a special thank you to those that have helped make this library better, including:\n\n@dev-jan @jisotalo\n\n## Version History\n\nPlease refer to CHANGELOG.md.\n","funding_links":["https://github.com/sponsors/jchristn","https://paypal.me/joelchristner"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjchristn%2Floggingmodule","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjchristn%2Floggingmodule","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjchristn%2Floggingmodule/lists"}