Create a task provider - Part 4

In this tutorial, we shall show you how to install the task provider we have created.

Manual Instalation

There're two steps to install the task provider manually

Copy the published binary to the plugin folder

If you have run the build script for engine, the plugin folder should be available in

.\publish\engine\plugins

Let's create a folder where our task provider shall be published into. Since it's a generator provider, it should be under GeneratorProvider folder:

.\publish\engine\plugins\GeneratorProvider\Polyrific.Catapult.TaskProviders.Angular

Now get the absolute path to this folder, then open a new shell, and go to our task provider source code project folder . Run the following command to publish our source code into the plugin folder:

dotnet publish --output "absolute path to .\publish\engine\plugins\GeneratorProvider\Polyrific.Catapult.TaskProviders.Angular"

Register the engine in the CLI

Remember earlier we created a plugin.yml file? Now is the time to use it. Open the opencatapult cli shell, login, then run this command:

dotnet occli.dll provider register --file "absolute path to Polyrific.Catapult.TaskProviders.Angular\plugin.yml"

And that's it, you can now create a generate task using the provider:

dotnet occli.dll task add --name Generate --type Generate --provider Polyrific.Catapult.TaskProviders.Angular

Provider Marketplace

[Coming soon]

Summary

That is it for the task provider tutorial. We hope it gives you a general idea on how opencatapult task provider work. If you want to learn more about other task providers, please go to the task provider reference‚Äč