With the loop on, the stop hook hands the session the next ready task (paused tasks are skipped, and overlane task next skips them too) whenever its task is submitted, verified or cancelled and the working copy is clean, up to –max tasks (default 20). A raised failure that no longer happens is cancelled with its evidence and the session moves straight on. It ends by itself when nothing is ready; off while tasks are still ready needs –even-if-ready. status shows how many tasks were handed. Local to this working copy.
Usage
overlane task loop [mode] [--max N] [--even-if-ready] [--dry-run]Arguments
| Argument | Required | Description |
|---|---|---|
mode |
no | on, off or status (default status) |
Flags
| Flag | Type | Required | Default | Description |
|---|---|---|---|---|
--max |
string | no | Most tasks to hand this session (default 20) | |
--even-if-ready |
boolean | no | Turn the loop off even though tasks are still ready | |
--dry-run |
boolean | no | Print the requests and file changes this command would make, then stop. Needs no credentials. |
Examples
overlane task loop on
overlane task loop on --max 5
overlane task loop offBehavior
- Effect:
write(changes local or hosted state). - Needs credentials: no. Uses the network: no.
- Supports
--dry-run: yes. Accepts--force: no. - Machine-readable description:
overlane schema task loop.
Result
With --json (the default when stdout is not a terminal) the command prints this JSON Schema’s shape on stdout.
{
"anyOf": [
{
"type": "object",
"properties": {
"on": {
"type": "boolean"
},
"state": {
"anyOf": [
{
"type": "object",
"properties": {
"on": {
"type": "boolean",
"const": true
},
"max": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"handed": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"last": {
"type": "string"
},
"startedAt": {
"type": "string"
}
},
"required": [
"on",
"max",
"handed",
"startedAt"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"localFile": {
"type": "string"
}
},
"required": [
"on",
"state",
"localFile"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"dryRun": {
"type": "boolean",
"const": true
},
"service": {
"type": "string"
},
"requests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"method": {
"type": "string"
},
"path": {
"type": "string"
},
"body": {},
"note": {
"type": "string"
}
},
"required": [
"method",
"path"
],
"additionalProperties": false
}
},
"commands": {
"type": "array",
"items": {
"type": "string"
}
},
"writes": {
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"action": {
"type": "string",
"enum": [
"write",
"append",
"delete"
]
},
"description": {
"type": "string"
}
},
"required": [
"path",
"action",
"description"
],
"additionalProperties": false
}
},
"notes": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"dryRun",
"requests",
"commands",
"writes",
"notes"
],
"additionalProperties": false
}
]
}See exit codes for the status the process returns.