Documentation
¶
Index ¶
- Constants
- func MakeOperateEnvDir(req command.Request, config repo_config_cli.Config, utilityName string) mad_env_dir.Env
- func MakeOperateEnvDirNoInit(req command.Request, config repo_config_cli.Config, utilityName string) mad_env_dir.Env
- type BlobStore
- func (cmd BlobStore) GetFlagValueBlobIds(blobStoreId *blob_store_id.Id) interfaces.FlagValue
- func (cmd *BlobStore) MakeBlobStoreFromIdOrConfigPath(envBlobStore env_repo.BlobStoreEnv, basePath string, ...) (blobStore blob_stores.BlobStoreInitialized)
- func (cmd *BlobStore) MakeBlobStoreFromIdString(envBlobStore env_repo.BlobStoreEnv, blobStoreIdString string) (blobStore blob_stores.BlobStoreInitialized)
- type Checkout
- type Complete
- func (cmd Complete) CompleteObjects(req command.Request, local *local_working_copy.Repo, ...)
- func (cmd Complete) CompleteObjectsIncludingWorkspace(req command.Request, local *local_working_copy.Repo, ...)
- func (cmd Complete) GetFlagValueMetadataTags(metadata objects.MetadataMutable) interfaces.FlagValue
- func (cmd Complete) GetFlagValueMetadataType(metadata objects.MetadataMutable) interfaces.FlagValue
- func (cmd Complete) GetFlagValueStringTags(value *values.String) interfaces.FlagValue
- func (cmd Complete) SetFlagsProto(proto *sku.Proto, flagSet interfaces.CLIFlagDefinitions, ...)
- type Env
- type EnvRepo
- type Genesis
- type InventoryLists
- type LocalWorkingCopy
- func (cmd LocalWorkingCopy) MakeLocalWorkingCopy(req command.Request) *local_working_copy.Repo
- func (cmd LocalWorkingCopy) MakeLocalWorkingCopyFromConfigAndXDGDotenvPath(req command.Request, xdgDotenvPath string, options env_ui.Options) (local *local_working_copy.Repo)
- func (cmd LocalWorkingCopy) MakeLocalWorkingCopyFromEnvLocal(req command.Request, envLocal env_local.Env) (local *local_working_copy.Repo)
- func (cmd LocalWorkingCopy) MakeLocalWorkingCopyWithOptions(req command.Request, envOptions env_ui.Options, ...) *local_working_copy.Repo
- func (cmd *LocalWorkingCopy) SetFlagDefinitions(f interfaces.CLIFlagDefinitions)
- type LocalWorkingCopyWithQueryGroup
- func (cmd LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroup(req command.Request, builderOptions queries.BuilderOption) (*local_working_copy.Repo, *queries.Query)
- func (cmd LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroupResolvingFilenames(req command.Request, builderOptions queries.BuilderOption) (*local_working_copy.Repo, *queries.Query)
- func (cmd *LocalWorkingCopyWithQueryGroup) SetFlagDefinitions(f interfaces.CLIFlagDefinitions)
- type ObjectMetadata
- func (cmd ObjectMetadata) GetFlagValueMetadataDescription(metadata objects.MetadataMutable) interfaces.FlagValue
- func (cmd ObjectMetadata) GetFlagValueMetadataTags(metadata objects.MetadataMutable) interfaces.FlagValue
- func (cmd ObjectMetadata) GetFlagValueMetadataType(metadata objects.MetadataMutable) interfaces.FlagValue
- type ParentBackedWorkspace
- func (cmd ParentBackedWorkspace) CreateRepoAndPullFromParent(req command.Request, absParentPath string, isHomeRepo bool, queryArgs []string, ...) (local *local_working_copy.Repo, remote repo.Repo)
- func (cmd *ParentBackedWorkspace) LinkParentZettelIdProviders(req command.Request, absParentPath string, isHomeRepo bool)
- func (cmd ParentBackedWorkspace) MakeParentRemote(req command.Request, local *local_working_copy.Repo, absParentPath string, ...) repo.Repo
- func (cmd ParentBackedWorkspace) ResolveParentPath(req command.Request) (absPath string, isHomeRepo bool)
- func (cmd ParentBackedWorkspace) RunEphemeral(req command.Request, pullQueryArgs []string, ...)
- func (cmd *ParentBackedWorkspace) SetupParentPointerBlobStore(req command.Request, workspaceRepoIdString string, absParentPath string, ...)
- func (cmd ParentBackedWorkspace) ValidateParentRepo(req command.Request, absPath string, isHomeRepo bool)
- type Query
- func (cmd Query) GetArgGroup() command.ArgGroup
- func (cmd Query) MakeQuery(req command.Request, options pkg_query.BuilderOption, workingCopy repo.Repo, ...) (query *pkg_query.Query)
- func (cmd Query) MakeQueryIncludingWorkspace(req command.Request, options pkg_query.BuilderOption, ...) (query *pkg_query.Query)
- func (cmd Query) MakeQueryResolvingFilenames(req command.Request, options pkg_query.BuilderOption, ...) (query *pkg_query.Query)
- func (cmd Query) RunOrganizeAgainstRemote(req command.Request, local *local_working_copy.Repo, remote repo.Repo, ...) (narrowed *pkg_query.Query)
- func (cmd *Query) SetFlagDefinitions(flagSet interfaces.CLIFlagDefinitions)
- type Remote
- func (cmd Remote) IsDirectTransfer() bool
- func (cmd Remote) IsHomeRepoParent() bool
- func (cmd Remote) IsWebSocketProtocol() bool
- func (cmd Remote) MakeDirectRemoteFromPath(req command.Request, local *local_working_copy.Repo) repo.Repo
- func (cmd Remote) MakeHomeRepoRemote(req command.Request) repo.Repo
- func (cmd Remote) MakeProtoConnectionFromObject(req command.Request, local *local_working_copy.Repo, object *sku.Transacted) (conn io.ReadWriteCloser, client *remote_proto.Client)
- func (cmd Remote) MakeRemote(req command.Request, repo *local_working_copy.Repo, object *sku.Transacted) (remote repo.Repo)
- func (cmd Remote) MakeRemoteAndObject(req command.Request, local *local_working_copy.Repo) (remote repo.Repo, remoteObject *sku.Transacted)
- func (cmd Remote) MakeRemoteFromBlob(req command.Request, repo *local_working_copy.Repo, blob repo_blobs.Blob) (remote repo.Repo)
- func (cmd Remote) MakeRemoteFromBlobAndSetPublicKey(req command.Request, repo *local_working_copy.Repo, ...) (remote repo.Repo)
- func (cmd *Remote) MakeRemoteHTTPFromXDGDotenvPath(req command.Request, xdgDotenvPath string, options env_ui.Options, ...) (remoteHTTP repo.Repo)
- func (cmd *Remote) MakeRemoteStdioLocal(req command.Request, env env_local.Env, dir string, ...) (remoteHTTP repo.Repo)
- func (cmd *Remote) MakeRemoteStdioSSH(req command.Request, env env_local.Env, arg string, ...) (remoteHTTP repo.Repo)
- func (cmd *Remote) MakeRemoteUrl(req command.Request, env env_local.Env, uri values.Uri, ...) (remoteHTTP repo.Repo)
- func (cmd *Remote) ResolveImplicitDirectPath(local *local_working_copy.Repo)
- func (cmd Remote) ResolvedFromParent() bool
- func (cmd *Remote) SetFlagDefinitions(flagSet interfaces.CLIFlagDefinitions)
- func (cmd Remote) VerifyOrPinParent(req command.Request, local *local_working_copy.Repo, remote repo.Repo)
- type RemoteRepoBlobs
- type RemoteTransfer
Constants ¶
const XDGUtilityNameMadder = "madder"
XDGUtilityNameMadder is the literal scope segment for madder's XDG namespace. Used as the second-env scope in env_repo.Make's two-env composition.
Variables ¶
This section is empty.
Functions ¶
func MakeOperateEnvDir ¶ added in v0.2.6
func MakeOperateEnvDir( req command.Request, config repo_config_cli.Config, utilityName string, ) mad_env_dir.Env
MakeOperateEnvDir builds one env_dir slot for the nearest-operate repo paths (show/query/edit, serve, info xdg/env), honoring every FDR-0019 cwd scope that resolves against an *existing* repo:
- system (`//name`) and explicit user (`name`): MakeDefaultAndInitialize preserves the scoped_id's LocationType — system roots at the system root (#280); an explicit XDG-user bare name pins to the XDG-user home with NO cwd walk-up (FDR-0019: bare name is XDG-user scope unconditionally, so it must not be hijacked to a workspace-local repo by an ancestor .dodder/).
- multi-dot cwd (`..name`, cwdDepth > 0): the Nth same-named ancestor, resolved store-aware via resolveCwdRepoAncestor, then rooted there (#281).
- everything else (auto, single-dot `.name`): MakeDefault's nearest-ancestor walk, unchanged.
utilityName selects the slot: the dodder metadata slot nests under repos/<name>/; the madder blob slot stays flat (repoName ""). Call it once per slot. The literal-init paths (genesis, MakeEnvRepo) deliberately stay on MakeDefaultAndInitialize(EffectiveId) instead — see repo_id.CheckSupported.
Exported because info's env/xdg display (uniform) shares it with the tango repo builders, so `info ..name xdg` reports the same path `show ..name` operates on.
func MakeOperateEnvDirNoInit ¶ added in v0.2.14
func MakeOperateEnvDirNoInit( req command.Request, config repo_config_cli.Config, utilityName string, ) mad_env_dir.Env
MakeOperateEnvDirNoInit computes a repo's on-disk paths for a root that may not exist yet, without the mkdir side effect, for existence checks (e.g. ParentBackedWorkspace.ValidateParentRepo probing a -parent path). Only the BasePath branch has genuinely side-effect-free behavior: its base dir is the explicit override, computed before any mkdir (madder#260). Every other branch still initializes — the default/XDG-user/system/cwd-multi-dot scopes address roots that already exist by the time an existence check reaches them (the home repo, an XDG-user repo), so the mkdir is a harmless no-op, and the only truly no-init constructor for the default branch (MakeDefaultNoInit) leaves the XDG base unpopulated — see the default-branch note below.
Types ¶
type BlobStore ¶
type BlobStore struct{}
func (BlobStore) GetFlagValueBlobIds ¶
func (cmd BlobStore) GetFlagValueBlobIds( blobStoreId *blob_store_id.Id, ) interfaces.FlagValue
func (*BlobStore) MakeBlobStoreFromIdOrConfigPath ¶
func (cmd *BlobStore) MakeBlobStoreFromIdOrConfigPath( envBlobStore env_repo.BlobStoreEnv, basePath string, blobStoreIndexOrConfigPath string, ) (blobStore blob_stores.BlobStoreInitialized)
func (*BlobStore) MakeBlobStoreFromIdString ¶
func (cmd *BlobStore) MakeBlobStoreFromIdString( envBlobStore env_repo.BlobStoreEnv, blobStoreIdString string, ) (blobStore blob_stores.BlobStoreInitialized)
type Checkout ¶
func (*Checkout) SetFlagDefinitions ¶
func (c *Checkout) SetFlagDefinitions(f interfaces.CLIFlagDefinitions)
type Complete ¶
type Complete struct {
ObjectMetadata
Query
}
func (Complete) CompleteObjects ¶
func (cmd Complete) CompleteObjects( req command.Request, local *local_working_copy.Repo, queryBuilderOptions pkg_query.BuilderOption, args ...string, )
func (Complete) CompleteObjectsIncludingWorkspace ¶
func (cmd Complete) CompleteObjectsIncludingWorkspace( req command.Request, local *local_working_copy.Repo, queryBuilderOptions pkg_query.BuilderOption, args ...string, )
func (Complete) GetFlagValueMetadataTags ¶
func (cmd Complete) GetFlagValueMetadataTags( metadata objects.MetadataMutable, ) interfaces.FlagValue
func (Complete) GetFlagValueMetadataType ¶
func (cmd Complete) GetFlagValueMetadataType( metadata objects.MetadataMutable, ) interfaces.FlagValue
func (Complete) GetFlagValueStringTags ¶
func (cmd Complete) GetFlagValueStringTags( value *values.String, ) interfaces.FlagValue
func (Complete) SetFlagsProto ¶
func (cmd Complete) SetFlagsProto( proto *sku.Proto, flagSet interfaces.CLIFlagDefinitions, descriptionUsage string, tagUsage string, typeUsage string, )
type Genesis ¶
type Genesis struct {
env_repo.BigBang
LocalWorkingCopy
BlobStore
}
func (Genesis) OnTheFirstDay ¶
func (cmd Genesis) OnTheFirstDay( req command.Request, ) *local_working_copy.Repo
func (*Genesis) SetFlagDefinitions ¶
func (cmd *Genesis) SetFlagDefinitions( flagSet interfaces.CLIFlagDefinitions, )
func (Genesis) SetLocationFromPositionalRequired ¶ added in v0.2.7
SetLocationFromPositionalRequired pops the required new-repo location positional and parses it into config.RepoId via the shared *Config pointer (FromAny returns a copy, so the mutation must go through the pointer). A non-auto config.RepoId means -repo_id / DODDER_REPO_ID was set, and under FDR-0021 T3-C those address an EXISTING repo rather than name a new one — so reject and point the caller at the positional.
type InventoryLists ¶
type InventoryLists struct{}
func (InventoryLists) MakeInventoryListCoderCloset ¶
func (InventoryLists) MakeInventoryListCoderCloset( envRepo env_repo.Env, ) inventory_list_coders.Closet
func (InventoryLists) MakeSeqFromPath ¶
func (InventoryLists) MakeSeqFromPath( ctx interfaces.ActiveContext, inventoryListCoderCloset inventory_list_coders.Closet, inventoryListPath string, afterDecoding func(*sku.Transacted) error, ) interfaces.SeqError[*sku.Transacted]
type LocalWorkingCopy ¶
type LocalWorkingCopy struct {
command_components.Env
}
func (LocalWorkingCopy) MakeLocalWorkingCopy ¶
func (cmd LocalWorkingCopy) MakeLocalWorkingCopy( req command.Request, ) *local_working_copy.Repo
func (LocalWorkingCopy) MakeLocalWorkingCopyFromConfigAndXDGDotenvPath ¶
func (cmd LocalWorkingCopy) MakeLocalWorkingCopyFromConfigAndXDGDotenvPath( req command.Request, xdgDotenvPath string, options env_ui.Options, ) (local *local_working_copy.Repo)
TODO modify to work with archives
func (LocalWorkingCopy) MakeLocalWorkingCopyFromEnvLocal ¶
func (cmd LocalWorkingCopy) MakeLocalWorkingCopyFromEnvLocal( req command.Request, envLocal env_local.Env, ) (local *local_working_copy.Repo)
MakeLocalWorkingCopyFromEnvLocal serves callers that already hold an env_local.Env for the own (dodder) scope — serve, serve-proto, and the HTTP/websocket remote server. envLocal's metadata XDG nests under repos/<name>/ (FDR-0019), so it is correct for the own slot but wrong for the blob-store slot: madder blob pools are separate, content- addressed, and never nest (see XDGUtilityNameMadder / configFor). The second slot is therefore built the same way the two-env builders do (env_dir.MakeDefault blanks RepoName for the madder utility and resolves the blob-store base via the madder XDG override / cwd walk), so opening a repo here lands on the same flat blob pool that init wrote and that ordinary commands read.
func (LocalWorkingCopy) MakeLocalWorkingCopyWithOptions ¶
func (cmd LocalWorkingCopy) MakeLocalWorkingCopyWithOptions( req command.Request, envOptions env_ui.Options, repoOptions local_working_copy.Options, ) *local_working_copy.Repo
func (*LocalWorkingCopy) SetFlagDefinitions ¶
func (cmd *LocalWorkingCopy) SetFlagDefinitions( f interfaces.CLIFlagDefinitions, )
type LocalWorkingCopyWithQueryGroup ¶
type LocalWorkingCopyWithQueryGroup struct {
LocalWorkingCopy
Query
}
func (LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroup ¶
func (cmd LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroup( req command.Request, builderOptions queries.BuilderOption, ) (*local_working_copy.Repo, *queries.Query)
func (LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroupResolvingFilenames ¶
func (cmd LocalWorkingCopyWithQueryGroup) MakeLocalWorkingCopyAndQueryGroupResolvingFilenames( req command.Request, builderOptions queries.BuilderOption, ) (*local_working_copy.Repo, *queries.Query)
func (*LocalWorkingCopyWithQueryGroup) SetFlagDefinitions ¶
func (cmd *LocalWorkingCopyWithQueryGroup) SetFlagDefinitions(f interfaces.CLIFlagDefinitions)
type ObjectMetadata ¶
type ObjectMetadata struct{}
func (ObjectMetadata) GetFlagValueMetadataDescription ¶
func (cmd ObjectMetadata) GetFlagValueMetadataDescription( metadata objects.MetadataMutable, ) interfaces.FlagValue
func (ObjectMetadata) GetFlagValueMetadataTags ¶
func (cmd ObjectMetadata) GetFlagValueMetadataTags( metadata objects.MetadataMutable, ) interfaces.FlagValue
func (ObjectMetadata) GetFlagValueMetadataType ¶
func (cmd ObjectMetadata) GetFlagValueMetadataType( metadata objects.MetadataMutable, ) interfaces.FlagValue
type ParentBackedWorkspace ¶ added in v0.2.14
type ParentBackedWorkspace struct {
Genesis
Query
// ParentPath is the explicit -parent path; empty means the home repo.
ParentPath string
// ParentRepoId, when non-empty, selects the parent repo by id via the
// FDR-0019 scope resolver — the same mechanism `show`/`cat-alfred`/the MCP
// use — instead of by -parent path or the home default. Takes precedence
// over ParentPath. It is the id's FULL spelling (scoped_id.String()): a
// bare name like "work" (XDG-user scope) or a cwd-scoped spelling like
// ".notes" / "..notes" (nearest / Nth-ancestor .dodder). parentConfig
// re-parses it via RepoId.Set, so the leading dots route through
// MakeOperateEnvDir's cwd branch. Empty leaves the -parent/home behavior.
ParentRepoId string
}
ParentBackedWorkspace bundles the create-a-repo-backed-workspace-pointing-at-a-parent sequence shared by `init-workspace -experimental-repo` and `edit -ephemeral`: resolve the parent repo (explicit -parent path or the home repo), wire a TomlPointerV1 blob store at the parent (FDR-0005, no blob copy), link the parent's zettel-id word lists, genesis the workspace repo (CWD-rooted via Genesis.OnTheFirstDay), and pull the queried objects from the parent.
The pieces are exposed individually so callers that interleave extra steps (init-workspace's -organize / -emit-inventory_list) can drive them directly; CreateRepoAndPullFromParent is the straight-line convenience used by the ephemeral path.
func (ParentBackedWorkspace) CreateRepoAndPullFromParent ¶ added in v0.2.14
func (cmd ParentBackedWorkspace) CreateRepoAndPullFromParent( req command.Request, absParentPath string, isHomeRepo bool, queryArgs []string, importerOptions repo.ImporterOptions, ) (local *local_working_copy.Repo, remote repo.Repo)
CreateRepoAndPullFromParent is the straight-line create-and-pull sequence used by the ephemeral path. It genesis-es the workspace repo (CWD-rooted; the caller is responsible for chdir-ing into the temp dir first), opens the parent as a remote, builds the query against the parent (which holds the tag/type definitions), and pulls the matching objects into the new repo. Both the new local repo and the parent remote are returned so the caller can drive a subsequent push back to the parent.
func (*ParentBackedWorkspace) LinkParentZettelIdProviders ¶ added in v0.2.14
func (cmd *ParentBackedWorkspace) LinkParentZettelIdProviders( req command.Request, absParentPath string, isHomeRepo bool, )
LinkParentZettelIdProviders sets BigBang.Yin and BigBang.Yang to the parent repo's word list files when neither flag was explicitly provided. This allows workspace repos to create new zettels using the parent's ID space without requiring the user to maintain separate word lists.
func (ParentBackedWorkspace) MakeParentRemote ¶ added in v0.2.14
func (cmd ParentBackedWorkspace) MakeParentRemote( req command.Request, local *local_working_copy.Repo, absParentPath string, isHomeRepo bool, ) repo.Repo
MakeParentRemote opens the resolved parent repo as a remote. For the home / -repo_id parent it builds the dodder + madder env_dirs through the FDR-0019 resolver (parentConfig -> MakeOperateEnvDir), the same mechanism the metadata and blob-store paths now use; for a -parent path it uses the direct-remote-from-path machinery.
func (ParentBackedWorkspace) ResolveParentPath ¶ added in v0.2.14
func (cmd ParentBackedWorkspace) ResolveParentPath( req command.Request, ) (absPath string, isHomeRepo bool)
ResolveParentPath mirrors init-workspace's parent resolution: an explicit -parent path (made absolute), an XDG-user -repo_id (resolved under the home XDG data dir, same root as the home repo — only the repos/<name> nesting differs, applied by the resolver via parentConfig), or, when both are unset, the home default repo.
func (ParentBackedWorkspace) RunEphemeral ¶ added in v0.2.14
func (cmd ParentBackedWorkspace) RunEphemeral( req command.Request, pullQueryArgs []string, work func(edited *local_working_copy.Repo) error, )
RunEphemeral drives the FDR-0023 ephemeral-workspace lifecycle shared by `edit -ephemeral` and `new -ephemeral`: materialize a temp repo-backed workspace whose blob store points at the resolved parent (zero-copy), pull the objects named by pullQueryArgs, run the caller's work against a fresh writable working copy of that workspace, push the result back to the parent, then tear the temp workspace down. On any failure after the workspace is created, the temp workspace is PRESERVED and its path surfaced so no work is lost.
The CALLER must, before calling, have (a) set ParentPath / ParentRepoId to select the parent and (b) overwritten config.RepoId with repo_id.CwdDefault() via the shared *repo_config_cli.Config pointer, so genesis roots the ephemeral repo (and its pointer blob store) inside the temp dir — see the per-command runEphemeral for why the config must be the shared pointer, not a FromAny copy.
work receives a fresh in-process working copy of the temp workspace (opened after CreateWorkspace, so it resolves as writable rather than the genesis env's read-only temporary). edit uses it to run the checkout/edit; new opens its own via runInWorkspace and ignores the argument — either is fine, both operate on the same temp workspace.
func (*ParentBackedWorkspace) SetupParentPointerBlobStore ¶ added in v0.2.14
func (cmd *ParentBackedWorkspace) SetupParentPointerBlobStore( req command.Request, workspaceRepoIdString string, absParentPath string, isHomeRepo bool, )
SetupParentPointerBlobStore configures Genesis.BigBang so that genesis writes a TomlPointerV1 instead of a freshly-initialized local-hash-bucketed store (#200). The pointer resolves to the parent repo's default blob store, so blob reads (e.g. parent's konfig) flow through to where the parent actually stores them.
The pointer id is "." + workspaceRepoIdString (CWD-scoped, prefixed with "." per dodder's blob_store_id convention). The base path is the parent's default-blob-store dir, obtained by building the parent's madder env_dir via the FDR-0019 resolver (parentConfig → MakeOperateEnvDir) and joining blob_stores/default under its data dir — replacing the previously hardcoded <madder>/blob_stores/default math, which could diverge from what the resolver produces under a non-default XDG_DATA_HOME (the bats sandbox). Closes #219.
type Query ¶
type Query struct {
sku.ExternalQueryOptions
}
func (Query) MakeQuery ¶
func (Query) MakeQueryIncludingWorkspace ¶
func (cmd Query) MakeQueryIncludingWorkspace( req command.Request, options pkg_query.BuilderOption, repo *local_working_copy.Repo, args []string, ) (query *pkg_query.Query)
func (Query) MakeQueryResolvingFilenames ¶
func (cmd Query) MakeQueryResolvingFilenames( req command.Request, options pkg_query.BuilderOption, repo *local_working_copy.Repo, args []string, ) (query *pkg_query.Query)
func (Query) RunOrganizeAgainstRemote ¶ added in v0.2.14
func (cmd Query) RunOrganizeAgainstRemote( req command.Request, local *local_working_copy.Repo, remote repo.Repo, qg *pkg_query.Query, instructions string, ) (narrowed *pkg_query.Query)
RunOrganizeAgainstRemote opens qg's matching objects, as resolved against remote (not the local store, since clone/init-workspace act on objects that don't exist locally yet), in an organize outline for accept/reject filtering, and returns a query narrowed to the surviving objects. Edits to tags/descriptions are not meaningful pre-pull, so only entry deletion (narrowing) is honored, mirroring checkout's -organize.
func (*Query) SetFlagDefinitions ¶
func (cmd *Query) SetFlagDefinitions(flagSet interfaces.CLIFlagDefinitions)
type Remote ¶
type Remote struct {
RemoteRepoBlobs
InventoryLists
LocalWorkingCopy
DirectPath string
RemoteConnectionType remote_connection_types.Type
// contains filtered or unexported fields
}
func (Remote) IsWebSocketProtocol ¶ added in v0.2.0
IsWebSocketProtocol reports whether the remote should be reached over the drtp websocket transport (sierra/remote_proto, RFC 0004) rather than the legacy remote_http backend.
func (Remote) MakeDirectRemoteFromPath ¶
func (Remote) MakeHomeRepoRemote ¶
func (Remote) MakeProtoConnectionFromObject ¶ added in v0.2.0
func (cmd Remote) MakeProtoConnectionFromObject( req command.Request, local *local_working_copy.Repo, object *sku.Transacted, ) (conn io.ReadWriteCloser, client *remote_proto.Client)
MakeProtoConnectionFromObject resolves a stored url remote object to a drtp websocket connection and a client bound to local. Used by pull/push when -remote-connection-type=url-websocket is set.
func (Remote) MakeRemote ¶
func (cmd Remote) MakeRemote( req command.Request, repo *local_working_copy.Repo, object *sku.Transacted, ) (remote repo.Repo)
returns a ready-to-use repo.Repo FROM an associated *sku.Transacted
func (Remote) MakeRemoteAndObject ¶
func (cmd Remote) MakeRemoteAndObject( req command.Request, local *local_working_copy.Repo, ) (remote repo.Repo, remoteObject *sku.Transacted)
returns a ready-to-use repo.Repo and an associated *sku.Transacted that can be persisted
func (Remote) MakeRemoteFromBlob ¶
func (cmd Remote) MakeRemoteFromBlob( req command.Request, repo *local_working_copy.Repo, blob repo_blobs.Blob, ) (remote repo.Repo)
returns a ready-to-use repo.Repo FROM an associated repo_blobs.Blob
func (Remote) MakeRemoteFromBlobAndSetPublicKey ¶
func (cmd Remote) MakeRemoteFromBlobAndSetPublicKey( req command.Request, repo *local_working_copy.Repo, blob repo_blobs.BlobMutable, ) (remote repo.Repo)
func (*Remote) MakeRemoteHTTPFromXDGDotenvPath ¶
func (*Remote) MakeRemoteStdioLocal ¶
func (*Remote) MakeRemoteStdioSSH ¶
func (*Remote) MakeRemoteUrl ¶
func (*Remote) ResolveImplicitDirectPath ¶
func (cmd *Remote) ResolveImplicitDirectPath( local *local_working_copy.Repo, )
func (Remote) ResolvedFromParent ¶ added in v0.2.7
ResolvedFromParent reports whether the remote was resolved from the workspace's recorded parent (path or home repo), as opposed to an explicit -direct path or a stored remote object. Only a parent-resolved remote is subject to #287b pubkey verification.
func (*Remote) SetFlagDefinitions ¶
func (cmd *Remote) SetFlagDefinitions( flagSet interfaces.CLIFlagDefinitions, )
func (Remote) VerifyOrPinParent ¶ added in v0.2.7
func (cmd Remote) VerifyOrPinParent( req command.Request, local *local_working_copy.Repo, remote repo.Repo, )
VerifyOrPinParent enforces the #287b parent-identity invariant before a push/pull whose remote was resolved from the workspace's parent. It is a no-op for any other remote (explicit -direct or a stored remote object).
- Pinned + live pubkey matches -> proceed.
- Pinned + mismatch -> hard error (the resolved parent is a different repo).
- Unpinned (legacy workspace) + TTY -> confirm-pin the resolved parent, upgrading the workspace config, then proceed.
- Unpinned + non-TTY -> hard error directing the user to `dodder set-parent`.
type RemoteRepoBlobs ¶
type RemoteRepoBlobs struct {
EnvRepo
}
func (RemoteRepoBlobs) CreateRemoteBlob ¶
func (cmd RemoteRepoBlobs) CreateRemoteBlob( req command.Request, local *local_working_copy.Repo, remoteType ids.Type, ) (blob repo_blobs.BlobMutable)
Returns a repo_blobs.BlobMutable that can be used to create a repo.Repo. The blob's public key SHOULD be set before writing it to the store.
func (*RemoteRepoBlobs) SetFlagDefinitions ¶
func (cmd *RemoteRepoBlobs) SetFlagDefinitions( flagSet interfaces.CLIFlagDefinitions, )
type RemoteTransfer ¶
type RemoteTransfer struct {
Remote
repo.ImporterOptions
}
func (*RemoteTransfer) SetFlagDefinitions ¶
func (cmd *RemoteTransfer) SetFlagDefinitions( flagDefinitions interfaces.CLIFlagDefinitions, )
Source Files
¶
- blob_store.go
- checkout.go
- complete.go
- env.go
- env_repo.go
- genesis.go
- inventory_lists.go
- local_working_copy.go
- local_working_copy_with_query_group.go
- object_metadata.go
- operate_env_dir.go
- organize_remote.go
- parent_backed_workspace.go
- query.go
- remote.go
- remote_repo_blobs.go
- remote_transfer.go