Rider templates

Configuring templates

Templates are provided by the Cake for Rider plugin.

Project templates

In the context menu of a solution in the project window, select Add | New Project to create a new project.

Run configurations

File templates

In the context menu of a solution item (project or folder) in the project window, select Add | Cake File to create a new Cake file containing some sample code.

Run configurations

Live templates (sometimes called code snippets)

Available live templates in Cake:

  • cake-addin

    • Provides a basic #addin pre-processor directive, where the package name and version can be changed
    • Default Value: #addin "nuget:?package=Cake.Foo&version=1.2.3"
  • cake-addin-full

    • Provides a more complete #addin pre-processor directive, where source, package name and version can be changed
    • Default Value: #addin "nuget:https://www.nuget.org/api/v2?package=Cake.Foo&version=1.2.3"
  • cake-argument

    • Provides code for basic input argument parsing, where variable name, argument name and default value can be changed
    • Default Value: var argumentName = Argument("Argument name", "Default value");
  • cake-load

    • Provides a basic #load pre-processor directive, where the path to the .cake file can be changed
    • Default Value: #load "scripts/utilities.cake"
  • cake-load-nuget

    • Provides a more complex #load pre-processor directive, where package name and version can be changed
    • Default Value: #load "nuget:?package=Cake.Foo&version=1.2.3"
  • cake-load-nuget-full

    • Provides a more complex #load pre-processor directive, where source, package name and version can be changed
    • Default Value: #load "nuget:https://www.nuget.org/api/v2?package=Cake.Foo&version=1.2.3"
  • cake-module-nuget

    • Provides a #module pre-processor directive, where package name and version can be changed
    • Default Value: #module "nuget:?package=Cake.Foo.module&version=1.2.3"
  • cake-module-nuget-full

    • Provides a more complex #module pre-processor directive, where source, package name and version can be changed
    • Default Value: #module "nuget:https://www.nuget.org/api/v2?package=Cake.Foo.module&version=1.2.3"
  • cake-reference

    • Provides a basic #reference pre-processor directive, where path to the assembly can be changed
    • Default Value: #reference "bin/myassembly.dll"
  • cake-sample

    • Provides a complete sample build Cake script including setup and teardown actions, a single task, and argument parsing
  • cake-tool

    • Provides a basic #tool pre-processor directive, where the package name and version can be changed
    • Default Value: #tool "nuget:?package=Cake.Foo&version=1.2.3"
  • cake-tool-full

    • Provides a more complete #tool pre-processor directive, where source, package name and version can be changed
    • Default Value: #tool "nuget:https://www.nuget.org/api/v2?package=Cake.Foo&version=1.2.3"
  • setup

    • Provides a sample setup definition
  • task-simple

    • Provides a basic task definition, where the name of the task can be changed
    • Default Value: Task("name");
  • task-action

    • Provides a more complex task definition, including a .Does body, where the name of the task can be changed
  • teardown

    • Provides a sample teardown definition

Available live templates in Cake Frosting:

  • cake-task
    • Provides a basic task definition class
  • cake-task-ctx
    • Provides a basic task definition class, using a custom Context
  • cake-async-task
    • Provides an async task definition class
  • cake-async-task-ctx
    • Provides an async task definition class, using a custom Context