git_policy_cli/invocation/mod.rs
1//! What:
2//! What one invocation does from arguments to Git:
3//! the decision,
4//! real Git resolution,
5//! forwarding,
6//! startup and management words.
7//! Why:
8//! The thin executables call into this folder first.
9//!
10//! In TS you'd write (pseudocode):
11//! ```ts
12//! // invocation/index.ts: one `export * from './file'` per module below.
13//! ```
14
15/// The decision one invocation ends in:
16/// become Git,
17/// or print and exit.
18pub mod action;
19
20/// The four top-level spellings after which the wrapper announces itself,
21/// and the text it prints once Git has answered.
22pub mod announced_query;
23
24/// Variables added to every real-Git child:
25/// lock PID injection and the forward-target marker.
26pub mod child_environment;
27
28/// Worktree target classification for worktree-enforcing policies.
29pub mod effective_target;
30
31/// The per-invocation decision the thin executable performs.
32pub mod entry;
33
34/// Spellings of the wrapper-only escape hatches shared by several modules.
35pub mod escape_hatch;
36
37/// Starting real Git with unchanged arguments,
38/// streams and exit status.
39pub mod forwarding;
40
41/// Git 2.56.0 global-argument boundaries over unchanged operating-system strings.
42pub mod global_arguments;
43
44/// The `git cli-git` decision:
45/// help,
46/// retired commands,
47/// and direct `check`/`fix`.
48pub mod management;
49
50/// The `git cli-git` argument grammar.
51pub mod management_arguments;
52
53/// The refusal of a direct command whose `--policy` selects a policy that is off.
54pub mod management_selection;
55
56/// PATH resolution of the real Git executable.
57pub mod real_git;
58
59/// Wrapper self-exclusion for one PATH candidate.
60pub mod real_git_candidate;
61
62/// The real Git that the commit service's unit file records, read as the fallback when `PATH` offers none.
63pub mod real_git_record;
64
65/// The one resolution of the real Git every start uses: `PATH`, then the Git the commit service's unit records.
66pub mod real_git_resolution;
67
68/// The marker every real-Git start carries and the check that stops a wrapper which finds it was started as Git.
69pub mod started_as_git;
70
71/// Wrapper-only control spellings,
72/// their meanings,
73/// and removal before the subcommand.
74pub mod wrapper_controls;
75
76/// Removal of every wrapper control from one invocation,
77/// by position.
78pub mod wrapper_invocation;
79
80/// The executable's panic hook:
81/// where an internal error happened,
82/// never its message.
83pub mod panic_notice;
84
85/// The names of the commands built into Git 2.56.0.
86pub mod git_builtins;
87
88/// The lifecycle of one wrapped Git command,
89/// from refusals to forwarding.
90pub mod wrapped_command;
91
92/// Every real-Git start of the wrapper carries `core.hooksPath` pointing at a directory that never exists.
93pub mod hooks_off;
94
95/// The startup step of a command: isolated merges whose process died, and what an earlier release left behind.
96pub mod startup_gate;
97
98/// The Git version check run once before work that depends on Git's behavior.
99pub mod git_version;
100
101/// The private per-user cache of the version text, keyed by the Git executable's identity.
102pub mod git_version_cache;
103
104/// The Git command a forwarded invocation runs,
105/// after ordinary alias expansion.
106pub mod forwarded_command;