pub struct RocflArgs {
    pub name: Option<String>,
    pub root: Option<String>,
    pub staging_root: Option<String>,
    pub region: Option<String>,
    pub bucket: Option<String>,
    pub endpoint: Option<String>,
    pub profile: Option<String>,
    pub quiet: bool,
    pub verbose: bool,
    pub no_styles: bool,
    pub command: Command,
}
Expand description

A CLI for OCFL repositories

rocfl provides a variety of subcommands for interacting with OCFL repositories on the local filesystem or in S3. Its goal is to provide a logical view of OCFL objects and make them easy to interact with in a unix-like way.

rocfl is able to interact with repositories without a defined storage layout, but this does come at a significant performance cost. Defining your OCFL storage layout is strongly recommended.

Each subcommand has its own help page that provides details about how to use the command. There are a number of global options that apply to most, if not all, subcommands that are described here. A number of these options, such as repository location information, can be defined in a configuration file so that they do not needed to be specified on every invocation. The easiest way to do this is by invoking: ‘rocfl config’.

Fields

name: Option<String>

Name of the repository to access

Repository names are used to load repository specific configuration in the rocfl config file. For example, a repository’s root could be defined in the config and referenced here by name so that the root does not need to be specified with every command.

root: Option<String>

Absolute or relative path to the repository’s storage root

By default, this is the current directory.

staging_root: Option<String>

Absolute or relative path to the staging directory

By default, versions are staged in an extensions directory in the main repository. This is the recommended configuration. If the repository is in S3, then versions are staged in an OS specific user home directory. Staging directories should NOT be shared by multiple different repositories.

region: Option<String>

AWS region identifier. Must specify when using S3.

bucket: Option<String>

S3 bucket name. Must specify when using S3.

endpoint: Option<String>

Custom S3 endpoint URL. Only specify when using a custom region.

profile: Option<String>

AWS profile to load credentials from.

quiet: bool

Suppress error messages and other command specific logging

verbose: bool

Increase log level

no_styles: bool

Disable all output styling

command: Command

Subcommand to execute

Trait Implementations

Append to Command so it can instantiate Self. Read more

Append to Command so it can update self. Read more

👎 Deprecated since 3.1.0:

Replaced with `CommandFactory::command

Deprecated, replaced with CommandFactory::command

👎 Deprecated since 3.1.0:

Replaced with `CommandFactory::command_for_update

Deprecated, replaced with CommandFactory::command_for_update

Build an Command that can instantiate Self. Read more

Build an Command that can update self. Read more

Formats the value using the given formatter. Read more

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

Assign values from ArgMatches to self.

Parse from std::env::args_os(), exit on error

Parse from std::env::args_os(), return Err on error.

Parse from iterator, exit on error

Parse from iterator, return Err on error.

Update from iterator, exit on error

Update from iterator, return Err on error.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

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

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more