Skip to main content

Commands

Enum Commands 

Source
pub enum Commands {
Show 33 variants Auth { cmd: AuthCmd, }, Install { target: String, }, Init { repository: Option<String>, provider: Option<String>, remote_url: Option<String>, workspace_id: Option<String>, remote: Option<String>, reset: bool, }, Configure { args: ConfigureArgs, }, Choose { cmd: ChooseCmd, }, Backend { cmd: BackendCmd, }, Completions { shell: Shell, }, Doctor { repair: bool, }, Status, Sync { repository: String, }, Create { entity_type: String, entity_id: String, repository: String, name: String, author: String, }, Resolve { uri: String, branch: Option<String>, commit: Option<String>, format: String, provenance: bool, include_blobs: bool, }, Presign { uri: String, representation: String, branch: Option<String>, commit: Option<String>, ttl_seconds: Option<u64>, http_url: Option<String>, token_env: Option<String>, }, Query { uri: String, path: String, format: String, }, Commit { repository: String, message: String, author: String, }, History { uri: String, limit: usize, }, List { repository: Option<String>, entity_type: Option<String>, }, Branch { repository: String, name: Option<String>, }, Set { uri: String, key: String, value: String, message: String, author: String, }, Add { uri: String, key: String, file: PathBuf, format: String, message: String, author: String, }, Revert { repository: String, commit: String, author: String, }, Pull { url_or_name: String, }, Push { repository: String, remote: String, branch: Option<String>, }, Remote(RemoteCmd), Sign { uri: String, }, Verify { uri: String, }, Switch { repository: String, name: String, }, Head { repository: String, }, Validate { uri: Option<String>, file: Option<PathBuf>, }, Schema { name: String, format: String, }, Diff { base_file: PathBuf, candidate_file: PathBuf, format: String, }, Merge { base: PathBuf, current: PathBuf, proposed: PathBuf, format: String, }, ContentHash { file: PathBuf, },
}

Variants§

§

Auth

Manage secure authentication for the configured Lore provider.

Fields

§cmd: AuthCmd

Authentication operation.

§

Install

Install required dependencies.

Fields

§target: String

Target to install (e.g., “lore” or “mcp”).

§

Init

Initialize a repository repository and/or configure the backend provider.

When a repository name is provided, creates the repository structure (directories, config, repository manifest, initial commit). When –provider is given (or no provider is configured), sets up the backend provider. Both can be combined:

px init toystory # create repository px init toystory –provider local # create repository + configure provider px init –provider local # configure provider only

Fields

§repository: Option<String>

Repository name. If provided, initializes a new repository repository.

§provider: Option<String>

Provider type: local, portals-cloud, or remote.

§remote_url: Option<String>

Remote URL (required for remote provider).

§workspace_id: Option<String>

Workspace ID (for remote provider).

§remote: Option<String>

Remote URL to add as origin after init.

This is deliberately --origin: --remote selects server-backed reads globally and must remain unambiguous on every command.

§reset: bool

Reset the provider configuration file.

§

Configure

Configure version-control backend (unified: replaces px choose + px backend).

Examples: px configure # show current config px configure status # show current config px configure local # switch to local daemon px configure remote –remote-url lore://192.168.0.27:41337 px configure portals-cloud –workspace-id my-ws px configure –provider remote –remote-url lore://host:41337 –reset

Fields

§

Choose

Choose backend provider (deprecated: use px configure).

Fields

§cmd: ChooseCmd

Subcommand for choose.

§

Backend

Configure or inspect the version-control backend (deprecated: use px configure).

Fields

§cmd: BackendCmd

Subcommand for backend.

§

Completions

Generate shell completions for px.

Usage: px completions bash > ~/.local/share/bash-completion/completions/px px completions zsh > ~/.zfunc/_px px completions fish > ~/.config/fish/completions/px.fish source <(px completions bash) # ephemeral

Fields

§shell: Shell

Shell to generate completions for.

§

Doctor

Run diagnostics and repair.

Fields

§repair: bool

Auto-repair detected issues.

§

Status

Show system status.

§

Sync

Sync with remote.

Fields

§repository: String

Repository name.

§

Create

Create a new entity manifest.

Fields

§entity_type: String

Entity type (any non-empty string, e.g. character, location, custom-type).

§entity_id: String

Entity ID (slug). e.g., “woody”.

§repository: String

Repository name.

§name: String

Human-readable name.

§author: String

Author identifier.

§

Resolve

Resolve a PX URI to its manifest or a subtree.

Fragment queries are supported via the URI: px resolve px://toystory/character/woody#references.appears_in

Fields

§uri: String

PX URI. e.g., “px://toystory/character/woody”

§branch: Option<String>

Resolve at a specific branch.

§commit: Option<String>

Resolve at a specific commit hash.

§format: String

Output format: yaml, json.

§provenance: bool

Include condensed per-file provenance for the manifest and direct representations.

§include_blobs: bool

Hydrate known readable provenance artifacts such as prompts and run records.

§

Presign

Create a time-limited public URL for a committed representation.

Fields

§uri: String

Entity ID, e.g. 25th-chapter/character/nathan-gunn. The px:// prefix is optional; fragments are not supported.

§representation: String

Representation name (manifest key), e.g. item. Its URI is relative to the entity’s asset directory.

§branch: Option<String>

Resolve at a specific branch.

§commit: Option<String>

Resolve at a specific commit hash.

§ttl_seconds: Option<u64>

Requested lifetime in seconds; Lore enforces its configured bounds.

§http_url: Option<String>

Explicit Lore HTTP origin, such as http://127.0.0.1:41339.

§token_env: Option<String>

Environment variable containing a repository-scoped bearer token.

§

Query

Query a subtree from a manifest.

Fields

§uri: String

PX URI.

§path: String

Dot-notation path. e.g., “appearances.audienceVotes”.

§format: String

Output format: yaml, json.

§

Commit

Commit changes to a repository repository.

Fields

§repository: String

Repository name.

§message: String

Commit message.

§author: String

Author identifier.

§

History

View commit history for an entity.

Fields

§uri: String

PX URI.

§limit: usize

Maximum number of commits to show.

§

List

List repositories or entities within a repository.

Fields

§repository: Option<String>

Repository name. Omit to list all repositories.

§entity_type: Option<String>

Entity type to list (if repository is specified).

§

Branch

Create or list branches.

Fields

§repository: String

Repository name.

§name: Option<String>

Branch name to create. Omit to list all branches.

§

Set

Set a property on an entity manifest.

Fields

§uri: String

PX URI.

§key: String

Property key (dot-notation).

§value: String

Property value.

§message: String

Commit message.

§author: String

Author identifier.

§

Add

Add a file representation to an entity manifest.

Fields

§uri: String

PX URI.

§key: String

Representation key. e.g., “reference_image”.

§file: PathBuf

File path to the asset.

§format: String

Asset format. e.g., “png”, “glb”.

§message: String

Commit message.

§author: String

Author identifier.

§

Revert

Revert a commit by hash (undoes all changes in that commit).

Fields

§repository: String

Repository name.

§commit: String

Commit hash to revert.

§author: String

Author identifier.

§

Pull

Clone or pull a repository from a remote.

If the argument is a URL, the repo is cloned (name is read from the repo’s own config). If it’s a repository name, the repo must already exist locally and will be updated via pull.

Fields

§url_or_name: String

URL (clone) or repository name (pull existing).

§

Push

Push the current branch to its configured upstream remote.

Fields

§repository: String

Repository name.

§remote: String

Remote name (default: tracking branch’s remote, or “origin”).

--remote selects server-backed reads globally; use this distinct spelling to name the push destination.

§branch: Option<String>

Branch to push (default: current branch).

§

Remote(RemoteCmd)

Manage remotes on a repository.

§

Sign

Sign a manifest (stub for v0).

Fields

§uri: String

PX URI.

§

Verify

Verify a manifest signature (stub for v0).

Fields

§uri: String

PX URI.

§

Switch

Switch to a branch.

Fields

§repository: String

Repository name.

§name: String

Branch name to switch to.

§

Head

Show the current HEAD commit hash.

Fields

§repository: String

Repository name.

§

Validate

Validate a manifest against the PX schema.

Fields

§uri: Option<String>

PX URI of the entity to validate.

§file: Option<PathBuf>

Path to a manifest YAML file to validate.

§

Schema

Print a JSON Schema for manifest or commit types.

Fields

§name: String

Schema name: ‘manifest’ or ‘commit’.

§format: String

Output format: json, yaml.

§

Diff

Show diff between two manifest files or versions.

Fields

§base_file: PathBuf

Base (left) manifest file.

§candidate_file: PathBuf

Candidate (right) manifest file.

§format: String

Output format: json, yaml.

§

Merge

Three-way merge of JSON/YAML values.

Fields

§base: PathBuf

Base (common ancestor) file.

§current: PathBuf

Current (ours) file.

§proposed: PathBuf

Proposed (theirs) file.

§format: String

Output format: json, yaml.

§

ContentHash

Compute the BLAKE3 content hash of a file.

Fields

§file: PathBuf

Path to the file to hash.

Trait Implementations§

Source§

impl Debug for Commands

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl FromArgMatches for Commands

Source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

impl Subcommand for Commands

Source§

fn augment_subcommands<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate Self via FromArgMatches::from_arg_matches_mut Read more
Source§

fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate self via FromArgMatches::update_from_arg_matches_mut Read more
Source§

fn has_subcommand(__clap_name: &str) -> bool

Test whether Self can parse a specific subcommand

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.