Skip to main content

InitiativeCommand

Enum InitiativeCommand 

Source
pub enum InitiativeCommand {
    Create {
        name: String,
        outcome: Option<String>,
        owner: Option<String>,
        status: Option<String>,
        priority: Option<String>,
        labels: Option<String>,
        target_date: Option<String>,
        projects: Option<String>,
        epics: Option<String>,
        milestones: Option<String>,
    },
    Edit {
        reference: String,
        name: Option<String>,
        outcome: Option<String>,
        owner: Option<String>,
        status: Option<String>,
        priority: Option<String>,
        labels: Option<String>,
        target_date: Option<String>,
        projects: Option<String>,
        epics: Option<String>,
        milestones: Option<String>,
    },
    List,
    Show {
        reference: String,
    },
    Delete {
        reference: String,
        yes: bool,
    },
    Associate {
        reference: String,
        project: Option<String>,
        epic: Option<String>,
        milestone: Option<String>,
    },
    Dereference {
        reference: String,
        project: Option<String>,
        epic: Option<String>,
        milestone: Option<String>,
    },
}
Expand description

The tix initiative subcommands (mission roadmap-initiatives-01M3C8SX, WP04).

A required subcommand, like tix project and tix epic. Selection is by the stable id (the registry key); a name resolves to the same initiative as a convenience. A rename through edit --name changes the label only: the id is not re-keyed, so every association and derived value survives.

Variants§

§

Create

Create an initiative and allocate a stable id

The name is a display label, not the identity: tix initiative edit --name changes it and every association survives, because the record is keyed by id.

Fields

§name: String

Display name (unique within the registry, case-insensitively)

§outcome: Option<String>

Optional strategic outcome

§owner: Option<String>

Owner identity string; no lookup, never inferred

§status: Option<String>

Free-form initiative status (not a board column)

§priority: Option<String>

Initiative priority (a known spelling is normalized; an unknown one is kept)

§labels: Option<String>

Filterable labels, comma-separated

§target_date: Option<String>

Target date (YYYY-MM-DD)

§projects: Option<String>

Project ids this initiative concerns, comma-separated

Shape-checked only, never resolved: a well-formed id the registry does not hold is stored and diagnosed by tix roadmap/tix lint, so it is repairable.

§epics: Option<String>

Epic ids this initiative concerns, comma-separated

§milestones: Option<String>

Milestone names this initiative concerns, comma-separated

§

Edit

Edit an initiative’s fields; a rename changes the label only

Nothing is re-keyed, so every association and derived value stays intact. An optional value with a blank spelling clears the field (--owner ""), and a blank reference list clears it (--projects "").

Fields

§reference: String

Initiative id (a name is accepted as a convenience)

§name: Option<String>

New display name

§outcome: Option<String>

New strategic outcome (--outcome "" clears)

§owner: Option<String>

New owner identity string (--owner "" clears)

§status: Option<String>

New free-form status (--status "" clears)

§priority: Option<String>

New priority (--priority "" clears)

§labels: Option<String>

Replace the label list, comma-separated (--labels "" clears)

§target_date: Option<String>

New target date (YYYY-MM-DD; --target-date "" clears)

§projects: Option<String>

Replace the project ids, comma-separated (--projects "" clears)

§epics: Option<String>

Replace the epic ids, comma-separated (--epics "" clears)

§milestones: Option<String>

Replace the milestone names, comma-separated (--milestones "" clears)

§

List

List initiatives in declaration order, with ids, target dates and status

§

Show

Show one initiative’s record, metadata and references

Fields

§reference: String

Initiative id (a name is accepted as a convenience)

§

Delete

Delete an initiative’s registry entry (nothing else is ever deleted)

The record’s own references are reported and nothing cascades: no project, epic, milestone or issue is touched, and no association is silently repaired.

Fields

§reference: String

Initiative id (a name is accepted as a convenience)

§yes: bool

Confirm without prompting

§

Associate

Associate an initiative with exactly one project, epic or milestone

Name exactly one of --project, --epic, --milestone; the kind is part of the record, so guessing is worse than asking. A well-formed reference that names nothing is stored and stays diagnosable, and a repeated association is an idempotent no-op that writes no bytes.

Fields

§reference: String

Initiative id (a name is accepted as a convenience)

§project: Option<String>

Project id to associate

§epic: Option<String>

Epic id to associate

§milestone: Option<String>

Milestone name to associate

§

Dereference

Drop an explicit association from an initiative

Name exactly one of --project, --epic, --milestone. Dropping an association that is not recorded is an idempotent no-op that writes no bytes.

Fields

§reference: String

Initiative id (a name is accepted as a convenience)

§project: Option<String>

Project id to drop

§epic: Option<String>

Epic id to drop

§milestone: Option<String>

Milestone name to drop

Trait Implementations§

Source§

impl FromArgMatches for InitiativeCommand

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 InitiativeCommand

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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
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.