1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
//! What:
//! What one invocation does from arguments to Git:
//! the decision,
//! real Git resolution,
//! forwarding,
//! startup and management words.
//! Why:
//! The thin executables call into this folder first.
//!
//! In TS you'd write (pseudocode):
//! ```ts
//! // invocation/index.ts: one `export * from './file'` per module below.
//! ```
/// The decision one invocation ends in:
/// become Git,
/// or print and exit.
/// The four top-level spellings after which the wrapper announces itself,
/// and the text it prints once Git has answered.
/// Variables added to every real-Git child:
/// lock PID injection and the forward-target marker.
/// Worktree target classification for worktree-enforcing policies.
/// The per-invocation decision the thin executable performs.
/// Plans what a forwarded Git command does: plain forward, settled worktree copy, or index-writer coordination.
/// Turns a plain forward of a push into a stacked or LFS-uploading push, with the notices a forward owes.
/// Runs coordinated and settled forwards and writes to the standard streams.
/// Spellings of the wrapper-only escape hatches shared by several modules.
/// Starting real Git with unchanged arguments,
/// streams and exit status.
/// Git 2.56.0 global-argument boundaries over unchanged operating-system strings.
/// The `git monochromatic-git-policy-cli` decision:
/// help,
/// retired commands,
/// and direct `check`/`fix`.
/// The direct `monochromatic-git-policy-cli` commands that run in this process, with their refusals.
/// Which repository the service commands mean.
/// `service settle-earlier-batches`, and the note `doctor` adds about the batches it would settle.
/// The `git monochromatic-git-policy-cli` argument grammar.
/// The refusal of a direct command whose `--policy` selects a policy that is off.
/// PATH resolution of the real Git executable.
/// Wrapper self-exclusion for one PATH candidate.
/// The real Git that the commit service's unit file records, read as the fallback when `PATH` offers none.
/// The one resolution of the real Git every start uses: `PATH`, then the Git the commit service's unit records.
/// The marker every real-Git start carries and the check that stops a wrapper which finds it was started as Git.
/// Wrapper-only control spellings,
/// their meanings,
/// and removal before the subcommand.
/// Removal of every wrapper control from one invocation,
/// by position.
/// The executable's panic hook:
/// where an internal error happened,
/// never its message.
/// The names of the commands built into Git 2.56.0.
/// The lifecycle of one wrapped Git command,
/// from refusals to forwarding.
/// The steps of a wrapped command beside its guarded stages: escape-hatch record, push failure notices, snapshots, manual push.
/// Every real-Git start of the wrapper carries `core.hooksPath` pointing at a directory that never exists.
/// The startup step of a command: isolated merges whose process died, and what an earlier release left behind.
/// The Git version check run once before work that depends on Git's behavior.
/// The private per-user cache of the version text, keyed by the Git executable's identity.
/// The Git command a forwarded invocation runs,
/// after ordinary alias expansion.