Skip to main content

Module connect

Module connect 

Source
Expand description

The steps of lean-ctx cloud connect after the device flow (CHECKLIST 2.1.1): the person confirms once per workspace what this machine shares with it, then the current project is mapped to its vault.

The answer is kept in <config_dir>/cloud/sharing.json (0600), so later sessions and later connects to the same workspace ask nothing. A “no” switches every outbound channel off in [cloud]. Pulling the workspace’s knowledge and policy goes on. Nothing here talks to Cloud.

Structs§

SharingDecision
What the person answered for one workspace.

Enums§

ProjectStep
What connect does for the project at root.

Constants§

SHARING_SCHEMA
SOURCE_BROWSER
SharingDecision::source of an answer given on the approval page.

Functions§

decision
The decision recorded for org_id. An answer for another workspace, another schema or a damaged file counts as none, so it is asked again.
project_step
The project step for root, from local state only.
record
Record the person’s answer for org_id, given in the terminal.
record_from
Record the person’s answer for org_id; source names where it was given (SOURCE_BROWSER), None for the terminal.
share_codes
shared_items as the C0 2.1 share codes the approval page words (knowledge, bus), sorted. usage and receipts are not sent by this version and are not announced.
shared_items
What leaves this machine for the workspace under config, one line each: exactly what the engine sends, nothing it does not. Empty when nothing does. Engine metrics are asked separately once released (engine_metrics_notice); usage totals and context receipts are not sent by this version.
switched_off_by_no
Every channel a “no” switches off is off: what without_sharing leaves. A yes given while it holds shares nothing until they are on again.
with_sharing
config with the channels a “no” switched off back at their defaults: what a later yes means.
without_sharing
config with every outbound channel off: what a “no” means.