Skip to content
PortBay

Qwen Code, dispatched with the same -p as its parent

Qwen Code is a Gemini CLI fork, so it takes the same prompt flag. PortBay runs `qwen -p` against a card in a project that is already serving, with a database attached and logs the agent can read.

The short answerVerified against the product, 2026-09-11

How do I run Qwen Code CLI on a task board?

PortBay detects the `qwen` binary on your PATH and offers Qwen Code in the agent picker alongside ten others. Assign it to a card, move the card to To Do, and PortBay spawns `qwen -p "<the card>"` headless with the working directory set to your project — the same prompt flag Gemini CLI takes, because Qwen Code is a fork of it. What changes the quality of the run is the environment on the other side: the project is already serving on its own .test hostname behind a certificate macOS trusts, a per-project database is attached with its connection variables injected, and outgoing mail is captured locally, so the agent can exercise what it wrote instead of reasoning about it. A model chosen on the card is appended as `-m`, matching Gemini's flag. Each card takes its own git worktree so parallel runs do not collide, and a strike system stops a card that has failed three times from re-dispatching.

In the app

qwen -p, pointed at a card

acme-shop · Board6 cards3 agents online
Pending2
infra
Rate-limit the API
P1
Dark mode polish
P2
Todo2
auth
Add OAuth login
P0Claude Code0/3oauth-login
Auto-dispatching
implement OAuth on app.test
db
Migrate to Postgres
P1
In Progress1
Fix flaky checkout test
P0
Done2
Set up Mailpit inbox
P2
Seed demo data
P2
1/5 · AssignA card lands in Todo and @claude is mentioned

Same invocation shape as Gemini, same board, same worktree — and the same running app to check the result in.

Walkthrough

Your first Qwen Code card

Five steps from a clean Mac to a Qwen Code run you can open in a browser. Every command runs as written.

  1. Install PortBay
  2. Add your project and press play
  3. Check qwen resolves
  4. Write a card and assign Qwen Code
  5. Move the card to To Do and review the running app

Install PortBay

Homebrew installs the app and the bundled portbay CLI. Prefer a direct download? Grab the DMG from GitHub Releases and drag PortBay.app into Applications.

brew tap portbay-app/portbay && brew install --cask portbay

Add your project and press play

PortBay reads the stack from the folder, fills in the runtime and port, issues the certificate and attaches a database. That environment is what the run inherits.

portbay add ~/code/myapp

Check qwen resolves

PortBay looks for the qwen binary on your PATH and shows it in the picker when it finds one. Set the path by hand if yours lives somewhere unusual. Authentication stays where Qwen Code already reads it.

which qwen

Write a card and assign Qwen Code

Brief the task and state the checkable outcome. Assign Qwen Code on the card, or set it as the board default. Pin a model on the card and PortBay appends -m to the command.

.portbay/tasks/normalize-address-fields.md

Move the card to To Do and review the running app

The run starts in its own worktree and comments what it changed when it ends. Open the project URL and use it. Require review holds the card until you approve.

https://myapp.test
Without PortBay

Qwen Code in a terminal tab

The command works fine on its own. It is the second and third task where the tab stops being enough.

A card keeps the brief in the repo, the run in its own worktree, and the result behind a URL you can open.

Questions

Asked before downloading

As a headless subprocess: `qwen -p "<the card>"`, with the working directory set to the project. Qwen Code is a Gemini CLI fork, which is why the prompt flag is identical.

No, and the difference is worth stating plainly: Gemini CLI is one of four agents PortBay wires in both directions, and Qwen Code is not, despite the shared lineage. Dispatch works in full; only the reverse direction is missing.

Yes. Qwen Code's short model flag is wired, so a model chosen on the card is appended as `-m <model>` — the same flag Gemini uses. Leave it unset and the CLI uses its own default.

Yes. Assign per card or set a board default, with a concurrency cap on how many run at once. Every card takes its own git worktree, so runs on the same repo never write the same file.

PortBay mascot — a friendly blue tugboat

Give your projects and your agents a real local home.

Download for macOS

Free & open source · macOS 11+ on Apple Silicon · Pro from $10/mo