vcspull sync - vcspull.cli.sync¶
Synchronization functionality for vcspull.
-
vcspull.cli.sync._visible_length(text)¶
Return the printable length of string stripped of ANSI codes.
-
class vcspull.cli.sync.PlanProgressPrinter¶
Bases:
objectRender incremental plan progress for human-readable dry runs.
-
vcspull.cli.sync._extract_repo_url(repo)¶
Extract the primary repository URL from a config dictionary.
- Parameters:
repo (ConfigDict)
- Return type:
-
vcspull.cli.sync._get_repo_path(repo)¶
Return the resolved filesystem path for a repository entry.
- Parameters:
repo (ConfigDict)
- Return type:
-
vcspull.cli.sync.clamp(n, _min, _max)¶
Clamp a number between a min and max value.
-
vcspull.cli.sync._maybe_fetch(repo_path, *, config)¶
Optionally fetch remote refs to provide accurate status.
-
vcspull.cli.sync._determine_plan_action(status, *, config)¶
Decide which plan action applies to a repository.
-
vcspull.cli.sync._update_summary(summary, action)¶
Update summary counters for the given plan action.
- Parameters:
summary (PlanSummary)
action (PlanAction)
- Return type:
-
vcspull.cli.sync._build_plan_entry(repo, *, config)¶
Construct a plan entry for a repository configuration.
- Parameters:
repo (ConfigDict)
config (SyncPlanConfig)
- Return type:
PlanEntry
-
async vcspull.cli.sync._build_plan_result_async(repos, *, config, progress)¶
Build a plan asynchronously while updating progress output.
- Parameters:
repos (list[ConfigDict])
config (SyncPlanConfig)
progress (PlanProgressPrinter | None)
- Return type:
PlanResult
-
vcspull.cli.sync._filter_entries_for_display(entries, *, show_unchanged)¶
Filter entries based on whether unchanged repos should be rendered.
-
vcspull.cli.sync._format_detail_text(entry, *, colors, include_extras)¶
Generate the detail text for a plan entry.
-
vcspull.cli.sync._render_plan(formatter, colors, plan, render_options, *, dry_run, total_repos)¶
Render the plan in human-readable format.
-
vcspull.cli.sync._emit_plan_output(formatter, colors, plan, render_options, *, dry_run, total_repos)¶
Emit plan output for the requested format.
-
vcspull.cli.sync.create_sync_subparser(parser)¶
Create
vcspull syncargument subparser.- Parameters:
parser (ArgumentParser)
- Return type:
-
vcspull.cli.sync.sync(repo_patterns, config, workspace_root, dry_run, output_json, output_ndjson, color, exit_on_error, show_unchanged, summary_only, long_view, relative_paths, fetch, offline, verbosity, sync_all=False, parser=None, include_worktrees=False)¶
Entry point for
vcspull sync.- Parameters:
- Return type:
-
vcspull.cli.sync._emit_summary(formatter, colors, summary)¶
Emit the structured summary event and optional human-readable text.
-
vcspull.cli.sync.progress_cb(output, timestamp)¶
CLI Progress callback for command.
-
vcspull.cli.sync.guess_vcs(url)¶
Guess the VCS from a URL.
-
exception vcspull.cli.sync.CouldNotGuessVCSFromURL¶
Bases:
VCSPullExceptionRaised when no VCS could be guessed from a URL.
-
exception vcspull.cli.sync.SyncFailedError¶
Bases:
VCSPullExceptionRaised when a sync operation completes but with errors.
-
vcspull.cli.sync.update_repo(repo_dict, progress_callback=None)¶
Synchronize a single repository.