git_policy_cli/lib.rs
1//! What:
2//! Internal native cli-git implementation,
3//! not yet the production executable.
4//! Why:
5//! The Rust rewrite preserves Git's own argument,
6//! repository and transaction semantics.
7//!
8//! In TS you'd write (pseudocode):
9//! ```ts
10//! // Internal modules used by the forthcoming native entry point and consumer verification.
11//! ```
12
13/// The decision one invocation ends in:
14/// become Git,
15/// or print and exit.
16pub mod action;
17
18/// Variables added to every real-Git child:
19/// lock PID injection and the forward-target marker.
20pub mod child_environment;
21
22/// The one failure type for rejected configuration content or files.
23pub mod config_error;
24
25/// Repository-root discovery and bounded reading of `cli-git.config.jsonc`.
26pub mod config_file;
27
28/// Lazy configuration loading for known inspection versus mutation/ambiguous commands.
29pub mod config_loading;
30
31/// Whole-document JSONC validation into typed settings.
32pub mod config_parse;
33
34/// Validation of the `policies` section and per-policy options.
35mod config_policies;
36
37/// The `rulesFile` option:
38/// a repository-relative name that stays inside the repository.
39pub mod config_rules_file;
40
41/// Typed settings and their defaults.
42pub mod config_schema;
43
44/// Key-naming typed readers over parsed JSONC values.
45mod config_values;
46
47/// JSONL event rendering for wrapper-made diagnostics.
48pub mod diagnostics;
49
50/// Worktree target classification for worktree-enforcing policies.
51pub mod effective_target;
52
53/// The per-invocation decision the thin executable performs.
54pub mod entry;
55
56/// Spellings of the wrapper-only escape hatches shared by several modules.
57pub mod escape_hatch;
58
59/// Starting real Git with unchanged arguments,
60/// streams and exit status.
61pub mod forwarding;
62
63/// Captured read-only real-Git queries over raw bytes.
64pub mod git_metadata;
65
66/// Git 2.56.0 global-argument boundaries over unchanged operating-system strings.
67pub mod global_arguments;
68
69/// Configuration of the repository one invocation selects.
70pub mod invocation_config;
71
72/// The `git cli-git` decision:
73/// help,
74/// retired commands,
75/// and direct `check`/`fix`.
76pub mod management;
77
78/// The `git cli-git` argument grammar.
79pub mod management_arguments;
80
81/// The fixed registry of shipped policies.
82pub mod policy_registry;
83
84/// PATH resolution of the real Git executable.
85pub mod real_git;
86
87/// Wrapper self-exclusion for one PATH candidate.
88pub mod real_git_candidate;
89
90/// Disposable fixtures shared by unit tests;
91/// never part of the release executable.
92#[cfg(test)]
93mod test_support;
94
95/// Repository and worktree identity as reported by real Git.
96pub mod worktree_identity;
97
98/// Git 2.56.0 `parse-options` tokenization of one command's argument region.
99pub mod command_options;
100
101/// Long-option matching:
102/// exact names,
103/// unique abbreviations and `no-` negation.
104mod command_options_long;
105
106/// Final-state and position questions over a tokenized region.
107pub mod command_options_query;
108
109/// Short-option clusters and their attached or following values.
110mod command_options_short;
111
112/// The shared decision of which bytes are an option's value.
113mod command_options_value;
114
115/// Real-Git fixtures and table oracles for command tests;
116/// never in the release build.
117#[cfg(test)]
118mod command_test_support;
119
120/// Differential harness over `git rev-parse --parseopt`;
121/// never in the release build.
122#[cfg(test)]
123mod command_test_parseopt;
124
125/// Table oracle over `--git-completion-helper-all`;
126/// never in the release build.
127#[cfg(test)]
128mod command_test_completion;
129
130/// Facts about the arguments after `git commit`.
131pub mod command_commit;
132
133/// The complete Git 2.56.0 option table of `git commit`.
134pub mod command_commit_table;
135
136/// The shared result and builder of transforms that add tokens to a command line.
137pub mod rule_argument_rewrite;
138
139/// Pure core of the index-against-`HEAD` check.
140pub mod rule_commit_index;
141
142/// Pure decision of the commit-only transform.
143pub mod rule_commit_only;
144
145/// User-facing diagnostics of the commit-only transform.
146pub mod rule_commit_only_message;
147
148/// Pure core of the merge,
149/// cherry-pick and revert conclusion check.
150pub mod rule_commit_sequencer;
151
152/// The Git 2.56.0 option table of `git push` and its facts.
153pub mod command_push;
154
155/// The Git 2.56.0 option table of `git status`,
156/// its facts and the advice-key reading.
157pub mod command_status;
158
159/// Pure decision of the atomic-push transform.
160pub mod rule_atomic_push;
161
162/// Pure decision of the status-hints transform.
163pub mod rule_status_hints;
164
165/// The Git 2.56.0 option table of `git add` and its bulk-staging facts.
166pub mod command_add;
167
168/// The Git 2.56.0 option table of `git clean` and its deletion facts.
169pub mod command_clean;
170
171/// The Git 2.56.0 option table of `git reset` and its mode.
172pub mod command_reset;
173
174/// `git stash` subcommand dispatch and wrapper-flag positions.
175pub mod command_stash;
176
177/// The Git 2.56.0 option tables of every `git stash` subcommand.
178pub mod command_stash_table;
179
180/// Branch-creation facts of `git branch`,
181/// `git checkout` and `git switch`.
182pub mod command_branch_create;
183
184/// Which action a tokenized `git branch` region selects.
185mod command_branch_mode;
186
187/// The complete Git 2.56.0 option table of `git branch`.
188pub mod command_branch_table;
189
190/// Explicit creation and the remote-guess candidate of `git checkout` and `git switch`.
191mod command_branch_target;
192
193/// The complete Git 2.56.0 option tables of `git checkout` and `git switch`.
194pub mod command_checkout_table;
195
196/// The Git 2.56.0 option groups of `git config`.
197pub mod command_config_table;
198
199/// The form and file scope of a `git config` region.
200pub mod command_config;
201
202/// Pure decision of the require-root policy.
203pub mod rule_require_root;
204
205/// Whether a `git worktree` invocation creates or moves a worktree.
206pub mod command_worktree;
207
208/// Wrapper-only control spellings,
209/// their meanings,
210/// and removal before the subcommand.
211pub mod wrapper_controls;
212
213/// Removal of every wrapper control from one invocation,
214/// by position.
215pub mod wrapper_invocation;
216
217/// Lifecycle triggers and the trigger set of every shipped policy.
218pub mod policy_trigger;
219
220/// Policy events and their JSON Lines rendering.
221pub mod policy_events;
222
223/// A pathname as events report it:
224/// text,
225/// plus base64 `pathBytes` when it is not UTF-8.
226pub mod event_path;
227
228/// Exact repository path bytes as the operating system takes them, and as text for messages.
229pub mod path_bytes;
230
231/// Ordered policy execution for one lifecycle point.
232pub mod policy_engine;
233
234/// Slice 6: writes one corrected file into the private commit index as a blob and an index entry.
235pub mod private_index_stage;
236
237/// Slice 6: the commit path's bounded policy convergence over the private index.
238pub mod commit_convergence;
239
240/// The commit transaction in the incumbent's order, up to the settled policies.
241pub mod commit_transaction;
242
243/// The conclusion of a settled commit transaction: preparation, landing and post-landing completion.
244pub mod commit_conclusion;
245
246/// The landing loop with replay, revalidation and the starvation reservation.
247pub mod commit_landing_loop;
248
249/// The landing lock a landing attempt takes, with the recovery every acquisition runs first.
250pub mod commit_landing_lock;
251
252/// Revalidation of a replayed tree outside both landing locks.
253pub mod commit_revalidation;
254
255/// The normalization-only transaction for a correction that removed every change.
256pub mod commit_no_change;
257
258/// The `git commit` command: the transaction, the settled events, the post-commit gate and the backup.
259pub mod commit_command;
260
261/// The disposable, recoverable workspace of one commit transaction.
262pub mod commit_workspace;
263
264/// Rule facts from the real repository with candidates read from the private index.
265pub mod commit_facts;
266
267/// The worktree completion records of selected corrections and of hook changes.
268pub mod commit_worktree_records;
269
270/// The replay-relevant commit options.
271pub mod commit_replay_options;
272
273/// Slice 9 skeleton: the order around a landed commit and a guarded Git child; not reachable until landing is merged.
274pub mod commit_lifecycle;
275
276/// The bounded loop that repeats a pass after corrections changed candidate content.
277pub mod policy_convergence;
278
279/// The one query for repository identity,
280/// top level and the path below it.
281pub mod repository_location;
282
283/// Lazily fetched repository facts behind one interface,
284/// with the real-Git provider.
285pub mod repository_facts;
286
287/// Pure decision of the linked-worktree-only policy.
288pub mod rule_linked_worktree;
289
290/// Pure decision of the branch-worktree-only policy and its one-query remote guess.
291pub mod rule_branch_worktree;
292
293/// Pure decision of the add-explicit policy.
294pub mod rule_add_explicit;
295
296/// The repository content the dependent-version planner reads, and its two failure kinds.
297pub mod dependent_version_content;
298
299/// Which paths the dependent-version planner reads: manifests, configuration, source.
300pub mod dependent_version_paths;
301
302/// Strict JSON reading of a manifest's name, version and dependency names.
303pub mod dependent_version_manifest;
304
305/// Patch bumps of plain release versions and `JSON.stringify` quoting.
306pub mod dependent_version_release;
307
308/// The byte-preserving rewrite of a manifest's top-level version.
309pub mod dependent_version_text;
310
311/// Publishable package names from the generated registry configuration.
312pub mod dependent_version_publishable;
313
314/// Whether source text imports a package.
315pub mod dependent_version_imports;
316
317/// The dependency walk and the plan of dependent bumps.
318pub mod dependent_version_graph;
319
320/// Every workspace manifest at both states, and which versions were raised.
321pub mod dependent_version_states;
322
323/// Which development dependencies each dependent bundles.
324pub mod dependent_version_bundled;
325
326/// The dependent-version plan with exact manifest bytes before and after.
327pub mod dependent_version_plan;
328
329/// The decision and findings of `mono/dependent-version-bump`.
330pub mod dependent_version_policy;
331
332/// The dependent-version planner's view of a prepared candidate state.
333pub mod dependent_version_lifecycle;
334
335/// Whether a direct fix may change a tracked file it did not select.
336pub mod policy_added_path;
337
338/// The `mono/dependent-version-bump` check over a lifecycle's candidate state.
339pub mod policy_dependent_version;
340
341/// An in-memory workspace that records reads; never in the release build.
342#[cfg(test)]
343mod dependent_version_test_support;
344
345/// Differential fixture reading and canonical results; never in the release build.
346#[cfg(test)]
347mod dependent_version_fixture_json;
348
349/// Canonical renderings of the native planner's results; never in the release build.
350#[cfg(test)]
351mod dependent_version_fixture_output;
352
353/// One differential case evaluated by the native planner; never in the release build.
354#[cfg(test)]
355mod dependent_version_fixture_cases;
356
357/// The native planner against the incumbent's recorded results; never in the release build.
358#[cfg(test)]
359mod dependent_version_differential_tests;
360
361/// The shipped policies as checks over rule cores and repository facts.
362pub mod policy_checks;
363
364/// What a lifecycle offers content policies,
365/// and its candidates once prepared.
366pub mod policy_content;
367
368/// The built-in final-newline policy:
369/// canonical final LF,
370/// preserved paths,
371/// findings.
372pub mod policy_final_newline;
373
374/// The optional root-context policy:
375/// no top-level `CONTEXT.md` enters the index.
376pub mod policy_root_context;
377
378/// The optional forbidden-strings policy over the linked scanner,
379/// with redacted findings.
380pub mod policy_forbidden_strings;
381
382/// One child program run with a time bound and output caps,
383/// through files instead of pipes.
384pub mod bounded_child;
385
386/// Where the `markdown/autofix` policy finds `monochromatic-lint`:
387/// absolute PATH entries only.
388pub mod markdown_linter_lookup;
389
390/// What one linter run printed:
391/// the fixed source and the findings left,
392/// or why it is unusable.
393pub mod markdown_linter_output;
394
395/// The one-rule linter configuration and the private temporary file it is written to.
396pub mod markdown_linter_config;
397
398/// The gitignore-syntax `exclude` patterns of `markdown/autofix`,
399/// matched as the linter matches them.
400pub mod markdown_exclude;
401
402/// The `markdown/autofix` policy over candidates,
403/// behind its linter interface.
404pub mod policy_markdown;
405
406/// The executable's linter for that policy:
407/// `monochromatic-lint` on PATH,
408/// bounded,
409/// once per candidate.
410pub mod markdown_linter;
411
412/// The executable's panic hook:
413/// where an internal error happened,
414/// never its message.
415pub mod panic_notice;
416
417/// Installing a direct fix's corrections into the worktree,
418/// all or none.
419pub mod direct_fix_install;
420
421/// The direct fix:
422/// converge corrections in memory,
423/// then install them.
424pub mod direct_fix;
425
426/// The fixed argument transforms of a forwarded command,
427/// in order.
428pub mod policy_transforms;
429
430/// One complete pass:
431/// built-in policies,
432/// fixed transforms,
433/// optional policies.
434pub mod policy_pass;
435
436/// The names of the commands built into Git 2.56.0.
437pub mod git_builtins;
438
439/// The work of the installed cli-git that is not ported,
440/// and the refusal notice.
441pub mod unported;
442
443/// The lifecycle of one wrapped Git command,
444/// from refusals to forwarding.
445pub mod wrapped_command;
446
447/// A scripted repository-facts provider for unit tests;
448/// never in the release build.
449#[cfg(test)]
450mod policy_test_support;
451
452/// The one failure type of the candidate layer and its closed list of causes.
453pub mod candidate_error;
454
455/// Validated Git object names and the file modes a candidate can carry.
456pub mod candidate_object;
457
458/// Pure framing of one `git cat-file --batch` reply.
459pub mod candidate_batch;
460
461/// Pure parsing of raw NUL-delimited changed-path records.
462pub mod candidate_record;
463
464/// The long-lived object reader that answers every blob read of an invocation.
465pub mod candidate_reader;
466
467/// Immutable candidate versions:
468/// identity,
469/// pathname,
470/// mode,
471/// change and object per path.
472pub mod candidate_version;
473
474/// Per-invocation listing,
475/// lazy bytes and invalidation of candidate versions.
476pub mod candidate_store;
477
478/// Pure parsing of `git ls-files --stage` records and the delta between two index states.
479pub mod candidate_stage;
480
481/// The files of a commit's tree with their modes and objects.
482pub mod candidate_tree;
483
484/// A private,
485/// timestamp-preserving copy of the real index,
486/// removed when dropped.
487pub mod candidate_private_index;
488
489/// What `git add` would stage,
490/// and the worktree files a direct command selects.
491pub mod candidate_prediction;
492
493/// The linked forbidden-strings scanner:
494/// one load per invocation,
495/// typed redacted findings.
496pub mod scanner_adapter;
497
498/// Rules-file precedence and which candidates the scanner is given.
499pub mod scanner_selection;
500
501/// One scan pass over a candidate version's exact bytes.
502pub mod scanner_run;
503
504/// Which engine failure code each candidate and scanner failure carries.
505pub mod scanner_failure_code;
506
507/// Process isolation and rule fixtures for scanner controls;
508/// never in the release build.
509#[cfg(test)]
510mod scanner_test_support;
511
512/// Private,
513/// crash-safe file primitives shared by every durable record.
514pub mod private_storage;
515
516/// Compact JSON records read and written with the incumbent's `JSON` semantics.
517pub mod json_record;
518
519/// Random identifiers in the layout of the incumbent's `randomUUID`.
520pub mod random_id;
521
522/// Text operations with the exact semantics of JavaScript's built-ins.
523pub mod js_text;
524
525/// Process-birth identities in the incumbent's exact spelling.
526pub mod process_identity;
527
528/// The owner record inside every owner-lock directory.
529pub mod owner_lock_record;
530
531/// Rename-published owner locks with dead-owner retirement and an unbounded wait.
532pub mod owner_lock;
533
534/// Line-oriented debug and warning diagnostics on standard error.
535pub mod diagnostic_log;
536
537/// The fail-closed failure of reading or recovering durable transaction state.
538pub mod recovery_error;
539
540/// The owner record of one commit-transaction directory and its liveness rule.
541pub mod transaction_owner;
542
543/// The per-worktree registry of commit-transaction directories.
544pub mod transaction_registry;
545
546/// The schema-version-2 journal records of one commit transaction and their filenames.
547pub mod transaction_journal;
548
549/// The exact encoding of every journal record.
550pub mod transaction_journal_encode;
551
552/// Strict parsers of every journal record.
553pub mod transaction_journal_parse;
554
555/// UTC timestamps in the exact form of JavaScript's `toISOString`.
556pub mod iso_time;
557
558/// The filesystem identity recorded with every real `index.lock` a transaction creates.
559pub mod filesystem_identity;
560
561/// Running real Git for transaction,
562/// recovery and landing work.
563pub mod transaction_git;
564
565/// The preparation and landing leases nested wrapper invocations inherit.
566pub mod transaction_lease;
567
568/// The dispatch plan of one commit transaction, its JSON spelling and the config reads it makes.
569pub mod hook_dispatch_plan;
570
571/// The hooks directory of one transaction: its plan and one entry per preparation event.
572pub mod hook_dispatch_entries;
573
574/// The hook dispatcher entered by a transaction's hook entry name, under the hook lock.
575pub mod hook_dispatch;
576
577/// No-follow file operations recovery and landing share.
578pub mod recovery_files;
579
580/// Durable evidence a dead transaction left:
581/// attempt records,
582/// owned locks and Git's PID file.
583pub mod recovery_evidence;
584
585/// The reflog search that proves which commit an interrupted transaction landed.
586pub mod recovery_reflog;
587
588/// Deciding whether a landing landed,
589/// and installing its recorded post-index.
590pub mod recovery_completion;
591
592/// The `.keep` files protecting a landing's migrated pack.
593pub mod pack_keep;
594
595/// Test-only transaction phase markers, compiled into the release executable and armed only by an environment variable.
596pub mod transaction_phase;
597
598/// Landing target comparison, nonce reflog message and compare-and-swap.
599pub mod landing_support;
600
601/// Migration of a prepared commit's shadow objects into a kept pack of the real store.
602pub mod landing_objects;
603
604/// Post-index a landing installs, computed against the real index at landing.
605pub mod landing_index;
606
607/// One landing attempt inside the landing critical section, and its outcome.
608pub mod landing_attempt;
609
610/// The `concurrent-commit` finding for a landing that landed nothing.
611pub mod landing_findings;
612
613/// Git commands run against a transaction's shadow repository.
614pub mod shadow_git;
615
616/// Native conclusion cleanup reproduced in the owning worktree.
617pub mod conclusion_cleanup;
618
619/// The per-worktree capture store:
620/// location,
621/// sequence and identity.
622pub mod capture_store;
623
624/// `captured.json`,
625/// landed-capture records,
626/// their recording and pruning.
627pub mod capture_records;
628
629/// Replay: the unified-diff parser of subsumption (`replay_patch`).
630pub mod replay_patch;
631
632/// Replay: the exact strict reverse check of subsumption (`replay_reverse_apply`).
633pub mod replay_reverse_apply;
634
635/// Replay: the one-sided extension of subsumption over zero-context hunks (`replay_containment`).
636pub mod replay_containment;
637
638/// Replay: raw commit objects as bytes, the unsigned rewrite and signed-rebuild inputs (`replay_object`).
639pub mod replay_object;
640
641/// Replay: capture order over the landed first-parent history and the per-path decision (`replay_capture_order`).
642pub mod replay_capture_order;
643
644/// Replay: the starvation reservation of the next landing slot (`replay_reservation`).
645pub mod replay_reservation;
646
647/// Replay: the shadow-repository Git runner that every replay step uses (`replay_shadow`).
648pub mod replay_shadow;
649
650/// Replay: shared paths of the landed history and the prepared commit, with their three entries (`replay_shared_paths`).
651pub mod replay_shared_paths;
652
653/// Replay: the text half of subsumption over index-named blobs and hunks (`replay_subsumption_text`).
654pub mod replay_subsumption_text;
655
656/// Replay: subsumption rules and the synthetic merge base (`replay_subsumption`).
657pub mod replay_subsumption;
658
659/// Replay: capture-order history and the per-path decisions from the transaction's and landed records (`replay_capture_history`).
660pub mod replay_capture_history;
661
662/// Replay: the merge tree, the first conflicting landed commit, and the replayed commit rebuild (`replay_merge`).
663pub mod replay_merge;
664
665/// Replay: the replayed index, the shadow HEAD move, and the pre-commit re-run decision of revalidation (`replay_revalidation`).
666pub mod replay_revalidation;
667
668/// Replay: one replay of a prepared commit onto a moved target, the integrator's replay result (`replay_commit`).
669pub mod replay_commit;
670/// The invocation capture:
671/// repository layout, symbolic `HEAD`, conclusion kind, ref backend and base.
672pub mod capture_invocation;
673
674/// The capture under capture order:
675/// the capture lock, the store identity, the sequence and `captured.json`.
676pub mod capture_order;
677
678/// The shadow repository `config` file and the copied repository format.
679pub mod shadow_config;
680
681/// The shadow repository links to the real shared entries.
682pub mod shadow_links;
683
684/// The shadow ref store: snapshot, private target, symbolic refs and `HEAD`.
685pub mod shadow_refs;
686
687/// The shadow conclusion copies at preparation.
688pub mod conclusion_copy;
689
690/// Argument transforms of native preparation: normalisation, global split, `-a` removal and private arguments.
691pub mod commit_args;
692
693/// The private commit index: copies, selection modes, pathspec files and listings.
694pub mod commit_index;
695
696/// Native `git commit` in the shadow, the prepared commit read back and `prepared.json`.
697pub mod commit_preparation;
698
699/// Creation of the shadow repository of one transaction.
700pub mod shadow_create;
701
702/// Loading many blobs through one `git cat-file --batch`.
703pub mod blob_batch;
704
705/// Bringing added paths' worktree copies to their landed bytes.
706pub mod worktree_completion;
707
708/// Owner inspection of registry entries and the oldest-first order.
709pub mod recovery_inspect;
710
711/// Recovery of one dead-owner transaction.
712pub mod recovery_landing;
713
714/// Disposal of a landed transaction: shadow removal, directory removal, then landed-capture pruning.
715pub mod landed_disposal;
716
717/// The post-commit run after a landing: author environment, hook lock, and the hook runner with inherited streams.
718pub mod post_commit_hook;
719
720/// Post-landing completion of one landed commit: worktree copies, disposal, maintenance, then `post-commit`.
721pub mod post_landing;
722
723/// Recovery across every transaction directory of one worktree.
724pub mod recovery_scan;
725
726/// Startup recovery of interrupted commit transactions.
727pub mod commit_recovery;
728
729/// Startup recovery as a step of a wrapped or direct command.
730pub mod transaction_gate;
731
732/// Process start times for lock owners,
733/// read from `/proc`,
734/// `ps` or the Windows process table.
735pub mod process_start;
736
737/// The Git version check run once before work that depends on Git's behavior.
738pub mod git_version;
739
740/// Processes holding a lock file open,
741/// found by device and inode.
742pub mod index_lock_holders;
743
744/// Parsers of `lsof -F pcDi` records and Restart Manager lines,
745/// matched by device and inode.
746pub mod index_lock_holder_parsers;
747
748/// Evidence about a foreign `index.lock` and the verdict it supports.
749pub mod index_lock_evidence;
750
751/// The Git command a forwarded invocation runs,
752/// after ordinary alias expansion.
753pub mod forwarded_command;
754
755/// Index-writer classification and the commands that coordinate with a landing.
756pub mod index_writer_commands;
757
758/// Waiting for a foreign index.lock under the classification rules and Git's backoff schedule.
759pub mod index_lock_wait;
760
761/// The host side effects of the index-lock wait:
762/// /proc reads,
763/// sleeps,
764/// randomness and standard error.
765pub mod index_lock_wait_host;
766
767/// The landing location a forwarded index writer coordinates with:
768/// the real index and the registry.
769pub mod landing_location;
770
771/// Coordination of a forwarded index writer:
772/// the landing lock,
773/// the wait for a foreign lock and the lease.
774pub mod index_writer_coordination;
775
776/// Running a coordinated forwarded index writer:
777/// the landing lock held while real Git runs as a child.
778pub mod index_writer_forward;
779
780/// The real index.lock a landing creates,
781/// identifies and releases only while it is the same file.
782pub mod real_index_lock;
783/// Automatic maintenance decision: config record parsing and the enable and detach rules.
784pub mod maintenance_decision;
785
786/// Running automatic maintenance after a landing: the config read, then `git maintenance run --auto`.
787pub mod maintenance_run;
788
789/// Catching SIGINT, SIGTERM, SIGHUP and SIGQUIT while a Git child runs, and relaying only process-sent signals.
790pub mod signal_relay;
791
792/// Exact removal of retired hk hook registrations from one explicit Git configuration scope.
793pub mod maintenance_hk_config;
794
795/// The per-branch push coordination file name: a reversible, flat, case-safe key.
796pub mod auto_push_branch_key;
797
798/// The per-branch `last-pushed` record: validation, tolerant reads and atomic publication.
799pub mod auto_push_record;
800
801/// Waiting for a lock a live process holds: a slow-wait notice naming the holder and a configurable backstop.
802pub mod live_lock;
803
804/// Read-only Git queries of the auto-push, each with a deadline and separate output streams.
805pub mod bounded_query;
806
807/// The auto-push's real `git push` with a deadline, its low-speed abort and the lock wait limit derived from it.
808pub mod bounded_push;
809
810/// Single-flight push coordination per branch: owner lock, record joins and the push itself.
811pub mod auto_push_single_flight;
812
813/// Post-commit auto-push of a landed commit: the push argv, the surfaced output and the failure reporting.
814pub mod auto_push;
815
816/// The post-commit gate over a landed commit: its events, its blocking and the backup it allows.
817pub mod post_commit;
818
819/// Authoritative manual-push updates discovered by a private dry-run push and confirmed with ls-remote.
820pub mod manual_push_probe;
821
822/// Published-set and range computation for manual-push scans: which pushed commits a remote does not have.
823pub mod manual_push_range;
824
825/// The manual-push candidate scope of one push: the commits and trees the destination lacks.
826pub mod manual_push_lifecycle;
827/// The one failure type of the linked-worktree ignored-state copy and its diagnostics.
828pub mod worktree_copy_error;
829
830/// Which linked worktrees a worktree-creating Git command registered, before and after it ran.
831pub mod worktree_copy_registry;
832
833/// The ignored source paths a linked-worktree copy selects, and the path validation every selection passes.
834pub mod worktree_copy_selection;
835
836/// The deterministic parent-first manifest of a copy, and the mode application to a staged copy.
837pub mod worktree_copy_manifest;
838
839/// Exact comparison of manifest entries against the filesystem, and the source stability check after staging.
840pub mod worktree_copy_compare;
841
842/// The private, validated stage of one source's ignored state beside a destination worktree.
843pub mod worktree_copy_stage;
844
845/// The exclusive creation of one destination entry from the stage, and the identity captured after it.
846#[cfg(unix)]
847pub mod worktree_copy_install_entry;
848
849/// Installation of a validated stage into a new worktree, with preflight, batches and rollback on failure.
850#[cfg(unix)]
851pub mod worktree_copy_install;
852
853/// Removal of the paths a failed installation created, only where their identity and content still prove them cli-git's own.
854#[cfg(unix)]
855pub mod worktree_copy_rollback;
856
857/// The durable journal of one copy: exact encoding, strict validation, private storage and removal.
858#[cfg(unix)]
859pub mod worktree_copy_journal;
860
861/// The durable claim on a stage container's name, and the removal of stages an interrupted copy left behind.
862#[cfg(unix)]
863pub mod worktree_copy_stage_claim;
864
865/// The append-only install log of one stage: per-batch intents and creations, with resumption.
866#[cfg(unix)]
867pub mod worktree_copy_install_log;
868
869/// One journaled installation to an end, resumption from the log, and synchronization of a created worktree.
870#[cfg(unix)]
871pub mod worktree_copy_transaction;
872
873/// The settlement lock that serializes copy installation and recovery, its owner record, and inherited leases.
874#[cfg(unix)]
875pub mod worktree_copy_lock;
876
877/// Recovery of interrupted copies: registration checks, discards with notices, resumption, and the pending check.
878#[cfg(unix)]
879pub mod worktree_copy_recovery;
880
881/// The linked-worktree ignored-state copy around one forwarded Git invocation: the integrator's entry point.
882#[cfg(unix)]
883pub mod worktree_copy;
884
885/// Which forwarded invocations the copy applies to, and the child run that carries its settlement lease.
886pub mod worktree_copy_forward;