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: docs/book/src/plugins/available/autoupdate-v1-alpha.md
+19-17Lines changed: 19 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,17 @@ Kubebuilder release is available — keeping your project **maintained, secure,
7
7
This automation uses the [`kubebuilder alpha update`][alpha-update-command] command with a **3-way merge strategy** to
8
8
refresh your project scaffold, and wraps it in a GitHub Actions workflow that opens an **Issue** with a **Pull Request compare link** so you can create the PR and review it.
9
9
10
+
<asideclass="warning">
11
+
<h1>Protect your branches</h1>
12
+
13
+
This workflow by default **only** creates and pushes the merged files to a branch
14
+
called `kubebuilder-update-from-<from-version>-to-<to-version>`.
15
+
16
+
To keep your codebase safe, use branch protection rules to ensure that
17
+
changes aren't pushed or merged without proper review.
18
+
19
+
</aside>
20
+
10
21
## When to Use It
11
22
12
23
- When you don’t deviate too much from the default scaffold — ensure that you see the note about customization [here](https://book.kubebuilder.io/versions_compatibility_supportability#project-customizations).
@@ -35,13 +46,14 @@ Whenever a new Kubebuilder release is available, the workflow will automatically
Moreover, AI models are used to help you understand what changes are needed to keep your project up to date,
39
-
and to suggest resolutions if conflicts are encountered, as in the following example:
49
+
By default, the workflow scaffolded uses `--use-gh-model` the flag to leverage in [AI models][ai-models] to help you understand
50
+
what changes are needed. You’ll get a concise list of changed files to streamline the review, for example:
51
+
52
+
<imgwidth="582"height="646"alt="Screenshot 2025-08-26 at 13 40 53"src="https://github.com/user-attachments/assets/d460a5af-5ca4-4dd5-afb8-7330dd6de148" />
40
53
41
-
<imgwidth="715"height="424"alt="AI Example Comment"src="https://github.com/user-attachments/assets/3f8bc35d-8ba0-4fc5-931b-56b1cb238462" />
54
+
If conflicts arise, AI-generated comments call them out and provide next steps, such as:
42
55
43
-
You will also see a list of files changed, making it easier to review the updates.
44
-
And, if conflicts arise, a summary of the conflicts will be provided to help you resolve them.
56
+
<imgwidth="600"height="188"alt="Screenshot 2025-08-26 at 13 41 02"src="https://github.com/user-attachments/assets/2142887a-730c-499a-94df-c717f09ab600" />
45
57
46
58
### Workflow details
47
59
@@ -66,15 +78,5 @@ The command called by the workflow is:
66
78
--use-gh-models
67
79
```
68
80
69
-
<asideclass="warning">
70
-
<h1>Protect your branches</h1>
71
-
72
-
This workflow by default **only** creates and pushes the merged files to a branch
73
-
called `kubebuilder-update-from-<from-version>-to-<to-version>`.
74
-
75
-
To keep your codebase safe, use branch protection rules to ensure that
76
-
changes aren't pushed or merged without proper review.
Copy file name to clipboardExpand all lines: docs/book/src/reference/commands/alpha_update.md
+26-32Lines changed: 26 additions & 32 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,23 +9,26 @@ not re-applying your code.
9
9
By default, the final result is **squashed into a single commit** on a dedicated output branch.
10
10
If you prefer to keep the full history (no squash), use `--show-commits`.
11
11
12
-
> **Tip:** You can reduce the burden of keeping your project up to date by using the
13
-
[`autoupdate.kubebuilder.io/v1-alpha`][autoupdate-plugin] plugin which
12
+
<asideclass="note">
13
+
<H1> Automate this process </H1>
14
+
15
+
You can reduce the burden of keeping your project up to date by using the
16
+
[AutoUpdate Plugin][autoupdate-plugin] which
14
17
automates the process of running `kubebuilder alpha update` on a schedule
15
18
workflow when new Kubebuilder releases are available.
16
-
>
17
-
> Moreover, you will be able to get help from AI models to understand what changes are needed to keep your project up to date
19
+
20
+
Moreover, you will be able to get help from [AI models][ai-gh-models] to understand what changes are needed to keep your project up to date
18
21
and how to solve conflicts if any are faced.
19
22
23
+
</aside>
24
+
20
25
## When to Use It
21
26
22
27
Use this command when you:
23
28
24
29
- Want to move to a newer Kubebuilder version or plugin layout
25
-
- Prefer automation over manual file editing
26
30
- Want to review scaffold changes on a separate branch
27
31
- Want to focus on resolving merge conflicts (not re-applying your custom code)
28
-
- Want an **AI-generated** overview of changes and guidance for resolving conflicts
29
32
30
33
## How It Works
31
34
@@ -171,15 +174,10 @@ The command opens an Issue that links to the diff so you can create the PR and r
171
174
172
175
With `--use-gh-models`, an AI comment highlights key changes and suggests how to resolve any conflicts:
173
176
174
-
<imgwidth="715"height="424"alt="AI Example Comment"src="https://github.com/user-attachments/assets/3f8bc35d-8ba0-4fc5-931b-56b1cb238462" />
Moreover, AI models are used to help you understand what changes are needed to keep your project up to date,
180
+
and to suggest resolutions if conflicts are encountered, as in the following example:
183
181
184
182
### Automation
185
183
@@ -210,6 +208,19 @@ kubebuilder alpha update \
210
208
--git-config rerere.enabled=true
211
209
```
212
210
211
+
<asideclass="note warning">
212
+
<h1>You might need to upgrade your project first</h1>
213
+
214
+
This command uses `kubebuilder alpha generate` under the hood.
215
+
We support projects created with <strong>v4.5.0+</strong>.
216
+
If yours is older, first run `kubebuilder alpha generate` once to modernize the scaffold.
217
+
After that, you can use `kubebuilder alpha update` for future upgrades.
218
+
219
+
Projects created with **Kubebuilder v4.6.0+** include `cliVersion` in the `PROJECT` file.
220
+
We use that value to pick the correct CLI for re-scaffolding.
221
+
222
+
</aside>
223
+
213
224
## Flags
214
225
215
226
| Flag | Description |
@@ -227,24 +238,6 @@ kubebuilder alpha update \
227
238
|`--use-gh-models`| Post an AI overview as an issue comment using `gh models`. Requires `gh` + `gh-models` extension. Effective only when `--open-gh-issue` is also set. |
228
239
|`-h, --help`| Show help for this command. |
229
240
230
-
<asideclass="note warning">
231
-
<h1>You might need to upgrade your project first</h1>
232
-
233
-
This command uses `kubebuilder alpha generate` under the hood.
234
-
We support projects created with <strong>v4.5.0+</strong>.
235
-
If yours is older, first run `kubebuilder alpha generate` once to modernize the scaffold.
236
-
After that, you can use `kubebuilder alpha update` for future upgrades.
237
-
238
-
</aside>
239
-
240
-
<asideclass="note">
241
-
<h1>CLI Version Tracking</h1>
242
-
243
-
Projects created with **Kubebuilder v4.6.0+** include `cliVersion` in the `PROJECT` file.
244
-
We use that value to pick the correct CLI for re-scaffolding.
245
-
246
-
</aside>
247
-
248
241
## Demonstration
249
242
250
243
<iframewidth="560"height="315"src="https://www.youtube.com/embed/J8zonID__8k?si=WC-FXOHX0mCjph71"title="YouTube video player"frameborder="0"allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"referrerpolicy="strict-origin-when-cross-origin"allowfullscreen></iframe>
@@ -267,3 +260,4 @@ so the current behavior may differ slightly from what is shown in the demo.
0 commit comments