korevDocs

Workspaces and branches

What a workspace is, where it lives, and how Korev names its branch.

A workspace is a git worktree on its own branch. Each workspace has its own files, chats, terminal, ports, diff and pull request. Agents in two workspaces never edit the same files, so you can run many tasks at once.

Where workspaces live

Korev puts each worktree at <workspaces location>/<repo>/<workspace name>. The default location is ~/korev/workspaces. Change it in Settings → Storage → Workspaces location. A repository with a worktree pool keeps its worktrees at <workspaces location>/<repo>/.pool/<n> instead.

All worktrees share the main checkout's .git folder, so they share commits, branches and remotes.

Names

Korev names a workspace from the first five words of the task, up to 40 characters. A name that is already taken gets -2, -3 and so on.

When Settings → Git → Name workspaces from the task is on (the default), Claude Haiku suggests a short name of two to four words. A workspace created without a task is named workspace. Korev renames its branch after your first message, if the branch was not pushed yet.

To give a workspace your own name, choose Rename in its … menu in the sidebar. Korev shows that name in place of the workspace name. The branch and the worktree folder do not change. Linked workspaces share the name.

Branches

The branch is <prefix>/<name>. Korev takes the prefix from the first of these that is set:

  1. [git] branch_prefix_type and branch_prefix in the repository config. branch_prefix_type = "none" means no prefix.
  2. Settings → Git → Branch prefix.
  3. Your GitHub login, from gh.
  4. Your git config user.name, or korev if that is empty.

Target branch

Every workspace has a target branch: the branch its pull request merges into. It starts as the repository's default branch. To change it, click → origin/<branch> in the workspace header.

The target branch decides the +N −M counts in the sidebar, the Changes tab, and the base of the pull request.

The .context folder

Every workspace has a .context/ folder. Korev adds it to the repository's .git/info/exclude, so git ignores it and nobody needs to change .gitignore.

  • Agents are told they can save files there to share notes with other agents, and to save the documents and screenshots they make for you there.
  • Each plan is saved to .context/plans/, in a file named from the plan's first heading. A revised plan with the same heading replaces the file.
  • Attachments you add to a chat are saved in .context/attachments/.
  • The Create PR prompt tells the agent not to commit it.

The Artifacts tab in the right panel lists the files in .context/, except attachments. Click a file to open it: markdown is rendered and images are shown. Right-click a file to reveal it in Finder or open it in its default app. When Korev cannot show a file, such as a video or a file over 1 MB, the tab has Open outside Korev. To point the agent at a file, drag it into the message box or type @ and its name.

Ports

Each active workspace gets ten ports. KOREV_PORT is the first one: 55000 for the first workspace, 55010 for the next, and so on. The agent is told to use $KOREV_PORT to $KOREV_PORT+9 for dev servers. Use the same variable in your run scripts so two workspaces never fight for a port. See Environment variables.

The sidebar row

  • Line 1 is the branch name. It is bold when the workspace has agent output you have not read.
  • Line 2 is the workspace name, a link icon for linked workspaces, and the error if setup failed.
  • The icon is a spinner while an agent or the setup script runs, a question mark while an agent waits for you, and a red warning sign when the setup or the agent failed. Otherwise it shows the pull request state: open, draft, checks running, checks failing, conflicts, merged or closed.
  • On the right are +N −M against the target branch and the unread dot.

Waiting for you

When a workspace waits for you, it also shows in Waiting for you at the top of the sidebar, so you do not have to scroll to its repository. The list shows workspaces whose agent asks you something or failed first, then workspaces whose pull request needs you, then Ask chats that ask you something, then workspaces whose agent finished while you were elsewhere. Click a row to open it. A finished workspace leaves the list when you open it. The list is hidden while nothing waits.

A pull request needs you when it has merge conflicts, a required check failed, or a review comment waits for your answer. A review comment waits for your answer when its thread is not resolved, the last comment in the thread is not yours, and a bot or a member or collaborator of the repository started the thread. The workspace's row shows a comment icon and the number of these threads. The workspace stays in the list until the pull request is fixed, also after you open it. With Keep PRs ready on, the workspace shows only after its agent tried and the problem is still there.

When you collapse a repository, a folder or a list of Ask chats, its header shows a dot if something in it waits for you. The dot is yellow when an agent asks you something or failed, or a pull request needs you. It is blue when an agent only finished.

Customize the sidebar

With many workspaces, the pages at the top of the sidebar (Search, New workspace, Grid, Board, Pull requests, Runs, Automations and New Ask) can push your workspaces down. Click the Customize sidebar icon at the top of the sidebar to change them:

  • Untick a page to hide it. You can still open it from the command palette (⌘K) or with its shortcut.
  • Turn on Compact navigation to show the pages as one row of icons. You can also run Compact sidebar navigation from the command palette.

Chat width

The chat keeps its text to a reading width in the middle of the window. A table or code block that does not fit grows into the space on both sides.

To use the whole width, click Wide chat, the icon at the right of the tab bar or in the Ask header. You can also run Wide chat from the command palette. Click it again to go back. The setting applies to every chat.

Folders in a repository

Put workspaces of one repository in a folder to keep them together.

  • Open a workspace's ⋯ menu. Under Move to folder, pick a folder, No folder, or New folder…. The menu lists up to two folders, the current one first. With more folders, More folders… opens a dialog where you can search for one.
  • Or drag a workspace onto a folder.
  • Click a folder to collapse or expand it. Its ⋯ menu renames or deletes it. Deleting a folder keeps its workspaces.
  • A folder shows only while it has a workspace that is not archived.
  • Lanes split off a plan get a folder of their own.

Switch workspaces with ⌘1 to ⌘9, ⌘⌥↑ and ⌘⌥↓, or the command palette (⌘K).

The command palette also searches the chats of every workspace, archived ones too, and of Ask. Type a PR number such as #292 to find the chats that mention or link that PR, and the workspace that tracks it. Pick a chat to open it.

Archive, restore and delete

Archive (⌘⇧A, or the ⋯ menu on the row):

  1. Stops the agents and terminals.
  2. Runs the archive script, for up to five minutes.
  3. Saves a snapshot of the files.
  4. Removes the worktree. A pooled worktree stays on disk, and the next new workspace reuses it.

The branch stays unless Settings → Git → Delete branch on archive is on.

Archive on merge (Settings → Git, or [git] archive_on_merge) archives a workspace when its pull request merges. Korev checks every 2 minutes, or right after an agent turn, and waits while an agent is running.

Archived workspaces are listed under History. Unarchive adds the worktree back, restores the snapshot, gives it new ports and runs setup again. Delete removes an archived workspace and its chat transcripts. It does not delete the branch.

On this page