Replace leaanthony/clir with spf13/cobra across all command packages. This provides better subcommand handling, built-in shell completion, and a more widely-used CLI framework. Changes: - Update cmd/core.go with cobra root command and completion support - Convert all subcommand packages to use *cobra.Command - Use init() functions for flag registration instead of inline setup - Maintain all existing functionality and flag behaviors Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
20 lines
648 B
Go
20 lines
648 B
Go
// Package vm provides LinuxKit virtual machine management commands.
|
|
//
|
|
// Commands:
|
|
// - run: Run a VM from image (.iso, .qcow2, .vmdk, .raw) or template
|
|
// - ps: List running VMs
|
|
// - stop: Stop a running VM
|
|
// - logs: View VM logs
|
|
// - exec: Execute command in VM via SSH
|
|
// - templates: Manage LinuxKit templates (list, build)
|
|
//
|
|
// Uses qemu or hyperkit depending on system availability.
|
|
// Templates are built from YAML definitions and can include variables.
|
|
package vm
|
|
|
|
import "github.com/spf13/cobra"
|
|
|
|
// AddCommands registers the 'vm' command and all subcommands.
|
|
func AddCommands(root *cobra.Command) {
|
|
AddVMCommands(root)
|
|
}
|