MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / Insert

Class Insert

atomic-cli/src/commands/insert.rs:40–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38/// - Cherry-pick specific changes (`pick`)
39#[derive(Debug, Args)]
40pub struct Insert {
41 #[command(subcommand)]
42 command: Option<InsertSubcommand>,
43
44 /// Hash of the change to insert (when not using subcommands).
45 ///
46 /// Omit entirely to promote the current view's changes into its parent
47 /// view (see the command-level docs).
48 #[arg(value_name = "CHANGE", add = ArgValueCompleter::new(complete_change_hashes))]
49 change: Option<String>,
50
51 /// Target view.
52 ///
53 /// For `atomic insert <hash>` this is the view the change is inserted
54 /// into (default: current view). For the bare `atomic insert` promotion
55 /// it overrides the target (default: the current view's parent).
56 #[arg(long, visible_alias = "to", add = ArgValueCompleter::new(complete_view_names))]
57 pub(crate) view: Option<String>,
58
59 /// Insert dependencies automatically. Pass `--deps=false` to skip the
60 /// dependency closure (the explicit opt-out the wire carries).
61 #[arg(long, action = clap::ArgAction::Set, num_args = 0..=1, default_value = "true", default_missing_value = "true")]
62 pub(crate) deps: bool,
63
64 /// Allow conflicts during insert.
65 #[arg(long)]
66 pub(crate) allow_conflicts: bool,
67
68 /// Preview the promotion without inserting anything.
69 #[arg(short = 'n', long)]
70 pub(crate) dry_run: bool,
71
72 /// Skip the confirmation prompt when promoting between two shared views.
73 #[arg(long)]
74 pub(crate) confirm: bool,
75
76 /// Repository path.
77 #[arg(short = 'R', long)]
78 repository: Option<String>,
79}
80
81/// Insert subcommands for cross-view operations.
82#[derive(Debug, Subcommand)]

Callers 2

insert_previewFunction · 0.85
diff_tokensFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected