Automatron.Tasks
0.0.0-alpha-11
This is a prerelease version of Automatron.Tasks.
There is a newer prerelease version of this package available.
See the version list below for details.
See the version list below for details.
Requires NuGet 5.9 or higher.
dotnet add package Automatron.Tasks --version 0.0.0-alpha-11
NuGet\Install-Package Automatron.Tasks -Version 0.0.0-alpha-11
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="Automatron.Tasks" Version="0.0.0-alpha-11" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Automatron.Tasks --version 0.0.0-alpha-11
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Automatron.Tasks, 0.0.0-alpha-11"
#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 Automatron.Tasks as a Cake Addin #addin nuget:?package=Automatron.Tasks&version=0.0.0-alpha-11&prerelease // Install Automatron.Tasks as a Cake Tool #tool nuget:?package=Automatron.Tasks&version=0.0.0-alpha-11&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Automatron.Tasks
The Automatron.Tasks .NET library is a task automation system that enables you to write task based workflows as .Net methods
Tasks can be are defined as void/async methods on one or many classes
Inheritance and interfaces are supported as well
Quick start
- Create a .NET console app named
Sample
and add a reference to Automatron.Tasks. - Replace the contents in
Program.cs
with:
using Automatron.Tasks;
using Automatron.Tasks.Annotations;
return await new TaskRunner().RunAsync(args);
namespace Sample;
public class Build
{
[Task(Default = true)]
public void Default()
{
Console.WriteLine("Hello, world!");
}
[Task]
public void Build()
{
Console.WriteLine("Building my app");
}
}
- Run the app. E.g.
dotnet run
or F5 in Visual Studio:
Tasks can be run via cmd arguments dotnet run -- Build
Dependencies
Dependencies are expression via the attributes
- DependentOn
- DependentFor
using Automatron.Tasks;
using Automatron.Tasks.Annotations;
return await new TaskRunner().RunAsync(args);
namespace Sample;
public class Build
{
[Task(Default = true)]
[DependentOn(nameof(Build))]
public void Default()
{
Console.WriteLine("Hello, world!");
}
[Task]
public void Build()
{
Console.WriteLine("Building my app");
}
}
Parameters
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net6.0
- Automatron (>= 0.0.0-alpha-11)
- CommandDotNet (>= 7.0.2)
- CommandDotNet.IoC.MicrosoftDependencyInjection (>= 5.0.1)
- CommandDotNet.NameCasing (>= 4.0.2)
- CommandDotNet.Spectre (>= 3.0.2)
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 |
---|---|---|
0.0.0-alpha-11.6 | 41 | 11/2/2024 |
0.0.0-alpha-11.5 | 50 | 10/12/2024 |
0.0.0-alpha-11.4 | 48 | 10/12/2024 |
0.0.0-alpha-11.3 | 42 | 10/6/2024 |
0.0.0-alpha-11.2 | 54 | 10/1/2024 |
0.0.0-alpha-11 | 108 | 6/2/2023 |
0.0.0-alpha.10 | 117 | 1/6/2023 |
0.0.0-alpha.9 | 102 | 1/2/2023 |
0.0.0-alpha.8 | 106 | 11/23/2022 |
0.0.0-alpha.7 | 98 | 11/21/2022 |
0.0.0-alpha.6 | 95 | 11/16/2022 |
0.0.0-alpha.4 | 104 | 11/15/2022 |
0.0.0-alpha.3 | 101 | 11/15/2022 |
0.0.0-alpha.2 | 102 | 11/11/2022 |
0.0.0-alpha.1 | 104 | 11/10/2022 |