A terminal task picker for VS Code style tasks.json files, built with Spectre.Console.
Run tman in a folder and it lists the tasks from .vscode/tasks.json and tasks.json. Pick one and it runs.
Inside Rex, each task opens in its own floating pane in tman's tab, so tman
keeps running and you can start more tasks while the first is still going.
dnx tmanRequires the .NET 10 SDK or later. tman is published on
nuget.org as a .NET tool, so dnx runs it without installing anything:
cd my-project
dnx tman # run it in the folder whose tasks you want
dnx tman ../api # or point it at a folder or a tasks.json fileOr install it as a tman command:
dotnet tool install -g tman # later: dotnet tool update -g tmanTo run it from source:
git clone https://github.com/kkukshtel/tman
cd my-project
dotnet run --project ../tmanPushing a version tag publishes that version to nuget.org through
.github/workflows/publish.yml:
git tag v0.1.0 && git push origin v0.1.0The tag sets the package version. The <Version> in Tman.csproj only names local builds. tman's own
.vscode/tasks.json has a release task that asks for the version and pushes the tag.
| Key | Action |
|---|---|
| ↑ / ↓, Home / End | Move (wraps around) |
| Type | Jump to a matching task |
| Enter | Run the task, or pick Refresh / Quit |
| Ctrl+C | Quit |
- Live reload. tman checks the tasks.json files a couple of times a second. When one is created, edited or deleted, the menu redraws. A file with a syntax error shows the line and column, and the menu recovers when you fix it. Refresh reloads on demand.
- Floating panes. Each task gets its own pane, labelled with the task name. The pane shows the command,
the output and the exit code, then waits for Enter before closing. Ctrl+C stops the task and leaves the pane
open so you can read the output. With
"presentation": { "close": true }the pane closes when the task ends. A task that fails straight away keeps its pane open either way. - Inputs.
${input:...}values are asked for in tman before the task starts:promptString(includingpassword) andpickString.
tman [options] [path]
path A directory (reads .vscode/tasks.json and tasks.json) or a tasks.json file.
-r, --run LABEL Run one task and exit. Handy for key bindings.
-l, --list Print the tasks as a table and exit.
--inline Run tasks in this terminal instead of Rex floating panes.
--no-focus Keep focus on tman when a floating pane opens.
--no-rc Don't read ~/.zshrc (or your shell's rc file) in task panes.
Outside Rex (REX_BLOCK isn't set), tman runs tasks in its own terminal and returns to the menu afterwards.
- JSON with comments and trailing commas
shell,processandnpmtasks. npm tasks use pnpm, yarn or bun when their lock file is present. Other types that have acommand(such ascppbuild) run likeprocesstasks.args, including{ "value": ..., "quoting": "escape" | "strong" | "weak" }options.cwd,options.envandoptions.shell, both global and per taskosx/linux/windowsoverrides, both global and per taskgroup, both a plain string and{ "kind", "isDefault" }. Groups become menu sections, and the default build task gets a ★ and starts selected.detail,hide,presentation.closedependsOnwithdependsOrder(parallelby default, orsequence). Dependencies can be labels or{ "type": "npm", "script": ... }. Cycles are reported instead of run.isBackgrounddependencies, such as watchers and dev servers, are started without waiting for them. They keep running until you close the pane.- Variables:
${workspaceFolder},${workspaceFolderBasename},${cwd},${userHome},${env:NAME},${pathSeparator},${/}and${input:id}
Not supported, because they need the VS Code editor: ${file} and other editor variables, ${config:...},
${command:...}, command inputs, and problem matchers. A task that uses one of these variables stops with a
message that names it, so it never runs with a broken command line.
tman turns the task and its dependencies into a small POSIX sh script. Each step is cd plus exec, with
every value single-quoted, and dependencies are combined in sequence or in parallel. In Rex it then calls
rex api call session.new_layer to open a floating terminal in tman's window that runs the script. That
terminal goes through your login shell, so tasks get the same PATH as your other terminals.