Call

The call keyword is used to include a reusable set of tasks in a run. There are three different types of things you can use with call:

  • Published packages: publicly published definitions of tasks providing common functionality such as installing a programming language or a particular CLI
  • Local packages: reusable sets of tasks defined in your project's .rwx/packages directory
  • Embedded runs: independent run definitions that can be embedded inside other run definitions

When to use a local package vs an embedded run

The following table illustrates the difference between local packages and embedded runs:

Local packagesEmbedded runs
Base and architectureInherit the base layers of the calling runDeclare their own base and their own architecture
Independent executionOnly run as part of a calling runCan be run independently, outside of being embedded in another run
Task dependenciesCan depend on other tasks and be depended on by other tasks with use or afterCannot depend on or be depended on by other tasks with use, but does support after
Common use casesSharing setup across a CI run and a sandbox run; running a parallel group with multiple tasks inside itSequencing a deploy run after a ci run; building binaries with multiple architectures