You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: BREAKING_CHANGES.md
+15-5Lines changed: 15 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,14 +35,14 @@ GitVersion is migrating away from LibGit2Sharp and its native libgit2 binaries t
35
35
36
36
| Release | Default backend | Switch |
37
37
| ------- | --------------- | ------ |
38
-
| v7.0 |`libgit2`|`GITVERSION_GIT_BACKEND=managed` to opt in to the new backend|
39
-
| v7.1 |`managed`|`GITVERSION_GIT_BACKEND=libgit2`to fall back|
40
-
|later|`managed`|libgit2 backend removed |
38
+
| v7.0 |`managed`|`GITVERSION_GIT_BACKEND=libgit2` is a temporary fallback|
39
+
| v7.1 |`managed`|libgit2 is removed; `libgit2`reports an actionable error, explicit `managed` remains accepted|
40
+
|v8|`managed`|the selector is removed |
41
41
42
42
Behavioral notes when using the `managed` backend:
43
43
44
44
* Mutating and network operations (repository normalization on CI build agents, dynamic repositories via `--url`, checkout, fetch) are performed by invoking the `git` executable, which must be available on the `PATH`. Plain version calculation on an already-prepared checkout does not require it.
45
-
*v7.0 behavior is unchanged unless you opt in. Please test the `managed`backend and report issues — the libgit2 backend will be removed once the new backend has proven itself over several releases.
45
+
*The default changes to `managed`in v7.0. LibGit2Sharp/native binaries remain available through the explicit fallback until their scheduled v7.1 removal.
46
46
47
47
### Invalid label formatting is not ignored
48
48
Previously bad label formatting config would be silently accepted. For example `{Branhc}` (when BranchName is misspelled) or even `{BranchName` (missing a closing brace). This is not ignored now and exceptions will be thrown if formatting problems exist in the label config. This brings it into line with how assembly string formatting is treated.
@@ -53,7 +53,13 @@ The command-line interface has been migrated from Windows-style (`/switch` and s
53
53
54
54
**Old-style arguments are no longer accepted by default.** Update any scripts, CI pipelines, or tooling accordingly.
55
55
56
-
As a temporary migration aid, set the environment variable `GITVERSION_USE_V6_ARGUMENT_PARSER=true` to restore the legacy `/switch` and `-switch` argument handling. This escape hatch will be removed in a future release.
56
+
As a temporary v7.0 migration aid, set `GITVERSION_ARGUMENT_PARSER_VERSION=v6` to restore legacy `/switch` and `-switch` handling. The default is `v7`. Unset `GITVERSION_USE_V6_ARGUMENT_PARSER`: any presence of that retired variable, including `false`, now fails with replacement guidance. The legacy parser is scheduled for removal in v7.1; the selector remains until v8.
57
+
58
+
The parser, configuration and Git backend selectors are independent. They trim
59
+
values, ignore case, treat blanks as unset and reject unknown values with the
60
+
accepted values. Effective selections are logged at information level; console
61
+
logs use stderr for machine-readable output, while build-server logs keep their
62
+
existing channel.
57
63
58
64
### Configuration structure and migration
59
65
@@ -75,6 +81,10 @@ writes YAML to stdout by default, supports `--config`, `--output`,
75
81
`--in-place`, and `--force`, and warns that comments cannot be preserved when
76
82
replacing a file.
77
83
84
+
Flat v6 runtime support is scheduled for removal in v7.1. Explicit `v7` remains
85
+
accepted throughout v7.x, and the configuration selector is removed in v8.
86
+
`gitversion config migrate`remains available after runtime removal.
87
+
78
88
#### Full argument mapping
79
89
80
90
| Old argument | New argument | Short alias | Env var alternative |
Copy file name to clipboardExpand all lines: docs/input/docs/migration/v6-to-v7.md
+26-7Lines changed: 26 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -51,7 +51,7 @@ GitVersion now uses POSIX-style command-line arguments powered by System.Command
51
51
:::{.alert .alert-warning}
52
52
**Breaking change:** Legacy Windows-style (`/switch`) and legacy single-dash long-form (`-switch`) arguments are no longer accepted by default.
53
53
54
-
As a temporary migration aid, set `GITVERSION_USE_V6_ARGUMENT_PARSER=true` to restore legacy argument handling. This compatibility mode is temporary and will be removed in a future release.
54
+
As a temporary v7.0 migration aid, set `GITVERSION_ARGUMENT_PARSER_VERSION=v6` to restore legacy argument handling. The legacy parser is removed in v7.1. Unset the retired `GITVERSION_USE_V6_ARGUMENT_PARSER` variable: its presence is an error, even when set to `false`; it is not an alias for the new selector.
55
55
:::
56
56
57
57
### What you need to change
@@ -149,14 +149,14 @@ migrate` to retain schema validation.
149
149
150
150
## Git backend
151
151
152
-
GitVersion v7 introduces a fully managed Git backend as an alternative to the native LibGit2Sharp (libgit2) implementation. The backend is selected with the `GITVERSION_GIT_BACKEND` environment variable. When the variable is not set (or empty), the release's default backend is used — you never need to set it. Setting it to any value other than `libgit2`or `managed` (case-insensitive) is an error: GitVersion fails fast instead of silently running the default backend with a typo unnoticed.
152
+
GitVersion v7.0 uses the managed Git backend by default. The `GITVERSION_GIT_BACKEND` environment variable accepts `managed`or the temporary `libgit2`fallback.
153
153
154
154
:::{.alert .alert-info}
155
-
In v7.0 the `libgit2`backend remains the **default** — behaviour is unchanged unless you opt in. Set `GITVERSION_GIT_BACKEND=managed` to try the managed backend and help validate it. In v7.1 the default flips to `managed`, with `GITVERSION_GIT_BACKEND=libgit2` available as a fallback. Both backends ship side by side for several releases before libgit2 is removed.
155
+
In v7.0, use `GITVERSION_GIT_BACKEND=libgit2`only if you need the temporary native backend fallback. LibGit2Sharp and its native binaries are scheduled for removal in v7.1. Explicit `managed` remains accepted throughout v7.x; the selector is removed in v8.
156
156
:::
157
157
158
-
-`libgit2` — the native, libgit2-based backend (default in v7.0).
159
-
-`managed` — a managed implementation for all read/history operations, combined with the `git` command-line executable for network and write operations (clone, fetch, checkout, and CI repository normalization).
158
+
-`libgit2` — the temporary nativebackend fallback in v7.0.
159
+
-`managed` — the v7.0 default: a managed implementation for all read/history operations, combined with the `git` command-line executable for network and write operations (clone, fetch, checkout, and CI repository normalization).
160
160
161
161
:::{.alert .alert-warning}
162
162
When using the `managed` backend, the `git` executable must be available on the `PATH`**only** for the network/normalization scenarios above (dynamic repositories, build-agent normalization). Plain version calculation on an already-prepared checkout does not require `git` on the `PATH`.
@@ -169,7 +169,26 @@ The environment variables relevant to migrating from v6 to v7:
Copy file name to clipboardExpand all lines: docs/input/docs/reference/environment-variables.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ Distinguish variables **read by GitVersion** from version variables **exported t
8
8
9
9
`Git_Branch` can identify the branch or tag when the build context is ambiguous. Provider-specific detection is described in the [CI guides](/docs/reference/build-servers). Ensure the selected reference and its history are available in the checkout.
10
10
11
-
The [v6 to v7 migration guide](/docs/migration/v6-to-v7#environment-variables) documents Git backend selection and temporary compatibility controls, including `GITVERSION_USE_V6_ARGUMENT_PARSER`. Compatibility switches are migration aids, not recommended defaults for a new setup.
11
+
The [v6 to v7 migration guide](/docs/migration/v6-to-v7#environment-variables) documents the independent selectors `GITVERSION_ARGUMENT_PARSER_VERSION`, `GITVERSION_CONFIGURATION_VERSION`, and `GITVERSION_GIT_BACKEND`. Their v7.0 defaults are `v7`, `v7`, and `managed`; temporary fallbacks are `v6`, `v6`, and `libgit2`. Values are trimmed and case-insensitive; blank values use the defaults and unknown values fail with accepted-value guidance. The retired `GITVERSION_USE_V6_ARGUMENT_PARSER` variable must be unset. Legacy implementations are removed in v7.1 and selectors in v8.
0 commit comments