ZsGWorks.UsageWatcher 1.2.3

There is a newer version of this package available.
See the version list below for details.
dotnet add package ZsGWorks.UsageWatcher --version 1.2.3
NuGet\Install-Package ZsGWorks.UsageWatcher -Version 1.2.3
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="ZsGWorks.UsageWatcher" Version="1.2.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add ZsGWorks.UsageWatcher --version 1.2.3
#r "nuget: ZsGWorks.UsageWatcher, 1.2.3"
#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.
// Install ZsGWorks.UsageWatcher as a Cake Addin
#addin nuget:?package=ZsGWorks.UsageWatcher&version=1.2.3

// Install ZsGWorks.UsageWatcher as a Cake Tool
#tool nuget:?package=ZsGWorks.UsageWatcher&version=1.2.3

Quality Gate Status Nuget

UsageWatcher

A simple way to watch mouse and keyboard usage for tracking purposes

Purpose

A central library for my own applications to watch for keyboard / mouse usage in order to track active computer use.

Feedback

If you feel like this is useful, or could be useful for you, feel free to create a feature request. If you think something is not working well, please create a bug report. Thank you!

How does it work

The idea is very simple: You pass a given 'resolution', like two minutes, and any mouse or keyboard movement within that timeframe will be considered an active time. If the computer is locked usage is not counted.

What it doesn't do

It's not logging anything. Neither software usage, nor which keys were pressed. You can check.

Usage

There is a probe project included, this line is taken from there:

IWatcher watcher = new Watcher("testApp", Resolution.HalfMinute, SavePreference.KeepDataForToday, DataPrecision.HighPrecision);

Then you can just ask, also from the probe project:

TimeSpan usage = watcher.UsageForGivenTimeframe(startTime, startTime + TimeSpan.FromDays(1));
Product Compatible and additional computed target framework versions.
.NET Framework net472 is compatible.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.1.0 359 10/7/2021
2.0.0 307 3/27/2021
1.2.3 316 3/9/2021
1.2.2 341 3/3/2021
1.2.1 312 3/2/2021

Fix for incorrect deserialization of data