Skip to content

Implement a new feature

Tasks are the main concept in Rover. Each task represents a unit of work that an AI coding agent will complete autonomously. This guide shows you how to create and manage tasks effectively.

Tasks can be as complex and large as needed. However, smaller, more focused tasks with clear descriptions and pointers make it easier for the agent to implement them successfully. Experiment to find what works best for your needs.

Every task in Rover has its own git worktree, allowing Rover to work on multiple tasks in parallel without conflicts between them or with your own work.

Create a simple task from scratch in your initialized repository.

Task Creation

  1. 1

    Navigate to a project that was previously initialized with Rover

    Terminal window
    cd ~/my-project
  2. 2

    Ask Rover to create a program, for example fizzbuzz

    Terminal window
    rover task -y "Create a fizzbuzz bash program as a programming example"
  3. 3

    Follow the progress of all tasks by watching the task list

    Terminal window
    rover list -w

    You can also follow the newly created task progress by following its logs. Assuming it got a Task ID of 1:

    Terminal window
    rover logs -f 1

Besides listing current tasks or watching the listing, you can inspect tasks and their iterations to understand what the agent planned and executed.

Inspecting tasks

  1. 1

    Inspect a task to see information about iterations and files

    Terminal window
    rover inspect 1
  2. 2

    If the previous step lists a plan.md file in the iteration details, check its contents

    Terminal window
    rover inspect 1 --file plan.md

Besides the plan, you can also check for the context.md, changes.md, and summary.md documents that represent: the context of the change, what changes need to be implemented, and the summary with all changes made by the agent.

Check what code changes the agent is proposing before integrating them into your codebase.

Check proposed diff

  1. 1

    View the diff of changes made by the agent

    Terminal window
    rover diff 1

Check the command reference to learn more about extra arguments and parameters the rover diff command supports.

To try the proposed changes, you can open a shell in the task’s git worktree using rover shell. By default, this uses your current $SHELL to spawn a new instance with the worktree as the current working directory.

Try proposed changes

  1. 1

    Open a shell in the task workspace

    Terminal window
    rover shell 1
  2. 2

    In this example, the agent created a fizzbuzz.sh file that you can try. Your mileage may vary.

    Terminal window
    sh fizzbuzz.sh

Within the workspace you can use git normally. The only special circumstance is that the system is inside a git worktree.

In this environment, you can run tests and perform checks to ensure the quality of the overall changeset.

If the agent has produced a result that needs small changes to be ready, you can add those changes directly to the worktree.

Improve proposed changes

  1. 1

    Open a shell in the task workspace

    Terminal window
    rover shell 1
  2. 2

    Edit the file, perform the required changes, and save it

    Terminal window
    $EDITOR fizzbuzz.sh
  3. 3

    Commit your changes

    Terminal window
    git commit -a -m 'chore: add version number to the output'
  4. 4

    Exit the shell environment by typing exit or pressing Ctrl+d