Skip to content

Commit 1384d1c

Browse files
authored
Merge pull request #414 from droot/delete-v0-commands
Delete v0 commands
2 parents 5ec3527 + 8915bdd commit 1384d1c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+108
-4188
lines changed

cmd/kubebuilder/v1/api.go renamed to cmd/kubebuilder/api.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package v1
17+
package main
1818

1919
import (
2020
"bufio"
@@ -42,7 +42,7 @@ type apiOptions struct {
4242

4343
// APICmd represents the resource command
4444

45-
func (o *apiOptions) RunAddAPI() {
45+
func (o *apiOptions) runAddAPI() {
4646
dieIfNoProject()
4747

4848
reader := bufio.NewReader(os.Stdin)
@@ -124,7 +124,7 @@ func (o *apiOptions) RunAddAPI() {
124124
}
125125
}
126126

127-
func AddAPICommand(cmd *cobra.Command) {
127+
func newAPICommand() *cobra.Command {
128128
o := apiOptions{}
129129

130130
apiCmd := &cobra.Command{
@@ -157,7 +157,7 @@ After the scaffold is written, api will run make on the project.
157157
make run
158158
`,
159159
Run: func(cmd *cobra.Command, args []string) {
160-
o.RunAddAPI()
160+
o.runAddAPI()
161161
},
162162
}
163163

@@ -171,7 +171,7 @@ After the scaffold is written, api will run make on the project.
171171
o.controllerFlag = apiCmd.Flag("controller")
172172
o.r = ResourceForFlags(apiCmd.Flags())
173173

174-
cmd.AddCommand(apiCmd)
174+
return apiCmd
175175
}
176176

177177
// dieIfNoProject checks to make sure the command is run from a directory containing a project file.

cmd/kubebuilder/build/build.go

Lines changed: 0 additions & 48 deletions
This file was deleted.

cmd/kubebuilder/create/config/config.go

Lines changed: 0 additions & 87 deletions
This file was deleted.

0 commit comments

Comments
 (0)