https://github.com/derekantrican/clockworkframework
An automation framework (running individual tasks on their own intervals) written in C#
https://github.com/derekantrican/clockworkframework
automation automation-framework csharp dotnet dotnet-core
Last synced: 2 months ago
JSON representation
An automation framework (running individual tasks on their own intervals) written in C#
- Host: GitHub
- URL: https://github.com/derekantrican/clockworkframework
- Owner: derekantrican
- License: mit
- Created: 2022-03-02T16:48:17.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2026-03-08T23:49:10.000Z (4 months ago)
- Last Synced: 2026-03-09T04:35:41.106Z (4 months ago)
- Topics: automation, automation-framework, csharp, dotnet, dotnet-core
- Language: C#
- Homepage:
- Size: 113 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Clockwork
[](https://www.nuget.org/packages/ClockworkFramework.Core/)
A basic automation framework for running tasks on an interval. Useful for things like periodically accessing an API, sending daily emails, etc
### Getting started
0. *Install .NET 8 if you do not have it installed already*
1. Clone the repo
2. Run `dotnet build`
3. Running the resulting executable will run the example tasks
**To set up your own library of tasks:**
1. Create a folder (ideally, not inside the ClockworkFramework folder)
2. Run `dotnet new console`
3. Run `dotnet add package ClockworkFramework.Core`
4. Add one or more classes that implement `IClockworkTaskBase` and a method with the `[TaskMethod]` & `[Interval(..)]` attributes (see [Examples](https://github.com/derekantrican/ClockworkFramework/tree/master/ClockworkFramework/Examples))
*For some common needs like calling an API or running a process you can use the `Utilties` class. See [ExampleApiTask](https://github.com/derekantrican/ClockworkFramework/blob/master/ClockworkFramework/Examples/ExampleApiTask.cs)*
5. In the same directory as ClockworkFramework.exe create `config.json`. Here is an annotated example:
```jsonc
{
"repositoryUpdateFrequency" : 5, // How often to update each library's repository (if it is a git repository) in minutes
"libraries" : [
{
"path" : "..\\..\\ClockworkTasks", // The path to the library. Can be relative or absolute. Can be a folder (containing a csproj), a csproj, or a dll
"updateRepository" : true // Whether to update the repository (with `git pull`) on the cadence in repositoryUpdateFrequency
}
]
}
```
6. Run the ClockworkFramework.exe to load your new library