aboutsummaryrefslogtreecommitdiffstats
path: root/share
Commit message (Collapse)AuthorAgeFilesLines
* continuum-party status: everything but the values, in colour, and as JSONtv2 days1-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `status` becomes the one place to look (party/status.rs): everything about the federation at the node but the values, which `get` and `values` read. * the store: its ID, checkpoint, heads, what it took, its stop; * the node: its party, whether it votes by itself, the revisions it knows; * the version: number, hash, federation, revision, how many pass a change; * every party: the keys its version names and its key set, --key's marked, and its nodes, each with its name, how long ago the node heard from it, and what it runs (wire versions, newest revision); * every proposal on the current version: how it stands, who voted what and who not yet, who proposed it and what it does (version_lines, as `show` says it), what moving to its checkpoint refuses, why no client backs it; * what the node refused of its own; * the party the client works as: its --key, its record held against the node's votes, what `again` signs again; * the warnings of what may keep votes away (cut_off). It is built as one JSON object (`model`), which `--json` writes, its `format` (FORMAT, 1) raised where it changes otherwise than by more members; what people read is rendered from it (`render`), and may change from release to release. On a terminal, in colour (Paint): true colour where COLORTERM says so, 256 where TERM does, else the basic eight; none with NO_COLOR, TERM=dumb, or off a terminal. What is fine is green, what needs a look yellow, what is wrong red; headings and the shortest prefix naming a proposal bold.
* continuum-party: a record held against the node's votes, a wait, restoretv2 days1-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A party votes from one record; a second record voting beside it, or one begun anew after a loss, can make the party vote twice. The client votes by its record, never by what a node shows, and still should look. Before a vote (`consistent`, `unrecorded`), the party's votes on the current version that the node shows (each proposal's yes and no) are held against the record's (Record::votes_cast): one the node shows that the record lacks refuses the vote, naming it and `restore`; one the record holds that the node doesn't show is said, as on its way or held back. Where they agree, nothing is said. What may keep a vote from the node is said too (`cut_off`, from counts' `heard`): the party's own nodes the node hasn't heard from in five minutes, through which another vote of it may have gone; and the parties none of whose nodes it heard from lately, where they are a third of those with nodes or more: a part of the swarm cut off. Then it waits (--wait SECONDS, 5 unless given, on vote and propose) and asks the node again: a vote cast elsewhere just before arrives first. A version passing meanwhile ends it, as the proposal lapsed. `restore` takes the party's votes on the current version, as the node holds them, into its record, or a new one of --party (Record::restore, checking each vote's signature, its party and version, none twice); a record begun on the current version casts on it then. Best effort: a vote on its way from elsewhere isn't among them, and what `again` signs anew, and the nays that freed an earlier `true`, it doesn't learn.
* continuum-party get: what counts, as JSON, a path at a timetv2 days1-4/+7
| | | | | | | | | | | | | | | What counts is kept by place, each place's value whole: `values` showed it so, a place a line, and `--json` as one object keyed by places. An application holds it as one tree. `get [PATH]` reads it so (tree, at): each place's value at its path, the maps on its way made, so that `get home/tv` is one object of everything under it, and `get home/tv/hosts/laptop/ip6` reaches into a place's value, a list's items by their index. Where a place lies under another's value, the deeper place is the later word there (merge). Nothing at a path is an error. `-r` writes a string as it is, as jq -r does; other values as JSON. Bash completes it with places and the paths on their way.
* continuum-party status: a key, a node, a party a line, nodes by their namestv2 days1-1/+1
| | | | | | | | | | | | | | | | `status` said each party's keys and nodes in one line, separated by commas, nodes by their IDs alone. Now each goes on a line of its own, indented beneath its heading (party_lines): the keys the version names, which sign votes, proposals, the key set and node list; those of the key set as it counts, which sign writes, or `the same`; `--key`'s marked, and said where it is none of them; and the nodes, each with the name it gave itself (`--alias`) where it did, as the dashboard names nodes. The store and the version are a heading each too, the parties one a line. The names come from GET /events/counts, which gives each party's `names` now (by node ID, of the nodes that gave themselves one), so that a party's session, which reads no /peers, has them. Bash completion reads the parties from the new layout.
* continuum-party keys: files of keys tootv2 days1-2/+6
| | | | | | | | `keys --add`, `--remove` and `--set` took authorized_keys lines alone, each one argument, so a .pub file went in as "$(cat phone.pub)". They take files of such lines too now, as `propose admit` and `propose keys` do (keys_given, of which key_lines is the one asking for a key at least), and bash completes files there.
* share/bash-completion: continuum-partytv2 days1-0/+241
A hand-written completion, where distributions package it: share/bash-completion/completions/continuum-party, read by bash-completion when first needed (it uses _init_completion and _filedir where they are, plain compgen else). It completes the commands, the intents of `propose` and `fork` (`fork` without `checkpoint`, with `proposal`), the options of each, files where one is taken, `--federation` from ~/.config/continuum/federations (or $XDG_CONFIG_HOME's), and `--revision` and `propose revision` from the features `--version` names. From the node, asked with the options given before the command: the proposals on the current version by hash (`proposals`), for vote, show and fork proposal; the parties (`status`), for remove, give, keys and nodes; and the places holding a value (`values`), for write and values.