A cross platform tool to read & query JSON aka CLEF log files created by Serilog
Releases are available on this GitHub Repository along on the Windows Store
The metrics for the MacOS usage was too little & I don't currently build/release any other Apple apps, so my Apple Developer subscription lapsed. I assumed the application would still be available to download but that I would not be able to push any new updates. However it seems Apple just removes the listing :(
For now I recommend you build it manually. In future I may do auto-updates via GitHub releases instead of app stores.
You will need the following installed:
- node/npm
- .NET Core SDK 2.2+
For OSX & Windows you can download the SDK here or install Visual Studio for Mac/Windows which includes the dotnet CLI tool
https://dotnet.microsoft.com/download
https://visualstudio.microsoft.com/vs/
- Clone Repo
- Open terminal in root of project
dotnet publish LogViewer.Server --runtime osx-x64 --output LogViewer.Server/bin/dist/osx --configuration release -p:PublishSingleFile=truegenerates a self contained application for our WebAPIdotnet publish LogViewer.Server --runtime win-x64 --output LogViewer.Server/bin/dist/win --configuration release -p:PublishSingleFile=truesame but creates the Windows version- Change terminal directory to
LogViewer.Clientfolder - Install TypeScript if missing
npm install -g typescript npm installtsc --watchThis will compile the TypeScript files & continue to watch them- Open a new terminal in
LogViewer.Client npm run startWill run the Electron app for development with Chrome DevTools open/launched
Note: If you
npm run startbefore you have compiled the TypeScript files then Electron will complain about not finding the entry point file. Additionally if you have also not rundotnet publishthen the underlying WebAPI which we communicate with will not be running.
This package uses the following libraries:
Changes made on the feature/Trimark_Tweaks branch for the Trimark edition of the viewer.
- .NET 10 -
LogViewer.ServerandLogViewer.Server.Testsnow targetnet10.0(wasnet7.0), withMicrosoft.AspNetCore.Mvc.NewtonsoftJsonupdated to 10.0.12. GitHub workflows install the .NET 10 SDK and the Azure pipeline uses thewin-x64runtime identifier. - Generic host -
Program.csusesHostBuilder+ConfigureWebHostin place of the deprecatedWebHostBuilder. - Trimmed publish fix -
PublishTrimmedon .NET 8+ disables a feature switch MVC needs and trims more aggressively, which crashed the server at startup. The project now setsTrimMode=partialandMvcEnhancedModelMetadataSupport=true.
- Product name is Trimark Compact Log Viewer and the version is 1.5.0 (client and server).
- The installer is
Trimark.Compact.Log.Viewer.Setup.<version>.exe, with matching shortcut, Add/Remove Programs, Microsoft Store and About box names. The window title is Compact Log Viewer (Trimark Edition). - Publishing and auto-update are disabled - electron-builder no longer publishes to GitHub releases, the Check for Updates menu item,
electron-updaterpackage anddev-app-update.ymlare removed, and CI no longer runs a publish step.
- Property name suggestions - while typing in the search box, property names found in the open log file (plus built-ins such as
@Leveland@Message) are suggested for the word at the caret. Use ↑/↓ to choose, Enter or Tab to insert and Escape to close. The server collects the names while parsing (GET api/viewer/properties). - Double-quoted strings - Serilog expressions only accept
'single quoted'strings, so an expression such asRequestMethod="POST"that fails to compile is retried with its double-quoted strings converted before falling back to a text search. - Enter runs the search, and the Search button now sits before Clear.
- Clickable properties - every property value in an expanded log entry (including
@MessageTemplate, nested object values and array items) is a link styled as plain text. Clicking it searches for that property and value, quoting the value according to its type.
- A Refresh dropdown next to the sort order (Disabled, 3, 5, 10 or 30 seconds). At the chosen interval the app asks the server whether the file has changed (
GET api/viewer/haschanged, comparing file size and last write time) and, only if it has, reloads it while keeping the current search, sort order and page. - The File has updates banner has been removed.
- Fixed the file watcher handler being added again on every reload.
- Rendered messages no longer wrap string property values in double quotes (
HTTP POST /apirather thanHTTP "POST" "/api"). - Log Levels lists Fatal down to Verbose, adds a Percent column (rounded to whole numbers) and shows the chart below the table.
- Properties of an expanded log entry are listed alphabetically after Timestamp and @MessageTemplate, with tighter row spacing.
- The sort order dropdown moved into the search card with Sort: labels, the pager is smaller and the error count panel is removed.
- The server must be published to
LogViewer.Server/bin/dist/winfor Electron to start it - re-rundotnet publish LogViewer.Server --runtime win-x64 --output LogViewer.Server/bin/dist/win --configuration Releaseafter any server change. - Packaging on Windows (
npm run win) needs Developer Mode turned on (or an administrator prompt) so electron-builder can extract its code signing tools; without it the exe keeps the default Electron icon and version details. - Electron 30 can fail to unpack its binary when installed under very new Node versions (e.g. Node 26), giving Electron failed to install correctly. Use Node 20 or 22 LTS for
npm install.
