Skip to content

Commit

Permalink
Merge pull request #3573 from yyy1000/doc
Browse files Browse the repository at this point in the history
馃摉 Add document for Alpha generate command
  • Loading branch information
k8s-ci-robot committed Aug 28, 2023
2 parents bddb6f5 + bca82df commit a361294
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions docs/book/src/reference/rescaffold.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Rescaffold Command

## Overview

The Kubebuilder CLI provides a new experimental helper `alpha generate` command to re-scaffold an existing project from the scratch using the current version of KubeBuilder binary available based on PROJECT config file.

## When to use it ?

This command is useful when you want to upgrade an existing project to the latest version of the Kubebuilder project layout. It makes it easier for the users to migrate their operator projects to the new scaffolding.

## How to use it ?

Currently, it supports two optional params, `input-dir` and `output-dir`.

`input-dir` is the path to the existing project that you want to re-scaffold. Default is the current working directory.

`output-dir` is the path to the directory where you want to generate the new project. Default is a subdirectory in the current working directory.

```sh
kubebuilder alpha generate --input-dir=/path/to/existing/project --output-dir=/path/to/new/project
```

0 comments on commit a361294

Please sign in to comment.