Output
By default, TAI will print human-readable output to the console. For example:
> tai-cli.exe verify --path="G:/tribes"
Reading local manifest from: G:\tribes\manifest.json
[1/34] Prerequisites: Verified
[2/34] Core: Verified
[3/34] Engine: Verified
⠋ Verifying...
While a slow step is running, an animated spinner is shown on the last line, so it's clear that TAI is still working. The spinner and text colours are only drawn when the output is an interactive terminal. When the output is piped or redirected, it's written as plain text (unless the -c flag is passed), and when -m or -s is passed, the spinner is omitted.
Passing the -m flag will instruct TAI to output machine-readable JSON instead of human-readable messages. For example:
> tai-cli.exe verify -m --path="G:/tribes"
{"type":"READING_LOCAL_MANIFEST","message":"Reading local manifest from: G:\\tribes\\manifest.json"}
{"type":"PROGRESS","index":1,"total":34,"message":"Prerequisites: Verified"}
{"type":"PROGRESS","index":2,"total":34,"message":"Core: Verified"}
{"type":"PROGRESS","index":3,"total":34,"message":"Engine: Verified"}
...
Machine-readable message types
ASSET_CREATEDASSETS_ARE_DAMAGEDCHECKING_ASSETSCHECKING_FOR_UPDATESDOWNLOAD_COMPLETEDOWNLOAD_PROGRESSDOWNLOAD_STARTEDDOWNLOADING_MANIFESTERRORFREE_SPACEINSTALL_FAILUREINSTALL_FOUNDINSTALL_INTERRUPTEDINSTALL_NOT_FOUNDINSTALL_PARTIALINSTALL_SUCCESSINSTALL_UP_TO_DATEINSTALL_VERIFIEDINSTALLINGINSTALLING_DEPENDENCIESINSUFFICIENT_SPACEINTERRUPTEDMANIFEST_CONTENTSMANIFEST_CREATEDMANIFEST_UNREADABLEPATCHING_ASSETSPREREQUISITES_DOWNLOADINGPREREQUISITES_FAILEDPREREQUISITES_INSTALLINGPREREQUISITES_REQUIREDPROGRESSPROMPT_PROCEEDPROMPT_UNINSTALL_ANYWAYREADING_LOCAL_MANIFESTREADING_MANIFEST_FAILEDREDOWNLOADINGREPO_FOUNDREPO_NOT_FOUNDRUNTIME_CHECK_FAILEDRUNTIME_CHECK_SKIPPEDRUNTIME_DAMAGEDRUNTIME_DOWNLOADINGRUNTIME_MISSINGRUNTIME_PREPARE_FAILEDRUNTIME_PREPARINGRUNTIME_READYRUNTIME_REPAIREDRUNTIME_VERIFIEDSETTINGS_REMOVE_FAILURESHORTCUTS_FAILURESHORTCUTS_REMOVE_FAILURESHORTCUTS_SUCCESSUNINSTALL_DEPENDENTSUNINSTALL_FAILUREUNINSTALL_INTERRUPTEDUNINSTALL_MATCHED_ALLUNINSTALL_ORPHANSUNINSTALL_PARTIALUNINSTALL_SUCCESSUNINSTALLINGUPDATE_FAILUREUPDATE_FOUNDUPDATE_INTERRUPTEDUPDATE_PARTIALUPDATE_SUCCESSUTILITIES_CHECK_SKIPPEDUTILITIES_DAMAGEDUTILITIES_FAILUREUTILITIES_REPAIREDUTILITIES_REPAIR_DEFERREDUTILITIES_SUCCESSUTILITIES_VERIFIEDVERIFY_INTERRUPTED
Download Progress
Assets are downloaded in batches and only logged as each one finishes, so a large download can remain on the same status line for a long time. When running in a terminal, a spinner is displayed, and describes the current action, progress, and remaining time estimate:
> tai-cli.exe install --path="G:/tribes"
Installing...
[1/34] Prerequisites: Downloaded
⠋ Downloading... 42% of 2.8 GB - 4 minutes left
Since TAI only provides this spinner when attached to a human-readable device, the -p flag can be passed to instruct TAI to produce JSON-formatted progress updates instead. When -p is provided, a download declares the total size, reports the number of bytes that have arrived with each progress update (several times per second), and declares when it is complete:
> tai-cli.exe install -p --path="G:/tribes"
...
{"size":2782785536,"message":"0% of 2.8 GB","type":"DOWNLOAD_STARTED"}
{"bytes":15728640,"size":2782785536,"rate":6553600,"message":"0% of 2.8 GB - 7 minutes left","type":"DOWNLOAD_PROGRESS"}
{"bytes":32505856,"size":2782785536,"rate":6684672,"message":"1% of 2.8 GB - 7 minutes left","type":"DOWNLOAD_PROGRESS"}
...
{"bytes":2782785536,"size":2782785536,"message":"100% of 2.8 GB","type":"DOWNLOAD_COMPLETE"}
| Property | Description |
|---|---|
size | The expected total number of bytes. |
bytes | The number of bytes that have been downloaded so far. |
rate | A smoothed average of the current download rate, in bytes per second. |
message | A human-readable description of the current progress. |
Notes:
- Lines produced by
-pare always JSON-formatted, regardless of-m. - A manifest with missing asset sizes can't be measured, and will report nothing rather than an inaccurate total.
Interrupting a Run
Pressing Ctrl+C stops a running subcommand at its next safe point (rather than killing it mid-write). TAI reports what was interrupted, which subcommand to run to resume the work, and exits with a non-zero status. Pressing Ctrl+C a second time ends the process immediately.
On Windows, a parent process that has no console of its own (eg, TAI GUI) can't send an interrupt signal. In this case, the subcommand can be stopped by writing "cancel" to TAI's standard input. To avoid conflicting with confirmation prompts, this is only listened for when standard input is a pipe (not a terminal).



