Go module, Makefile with standard targets, golangci-lint v2 config, CLAUDE.md, and empty CLI/agent binaries. Build, vet, and lint all pass. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
34 lines
522 B
Go
34 lines
522 B
Go
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
var (
|
|
version = "dev"
|
|
cfgPath string
|
|
)
|
|
|
|
func main() {
|
|
root := &cobra.Command{
|
|
Use: "mcp-agent",
|
|
Short: "Metacircular Control Plane agent",
|
|
}
|
|
root.PersistentFlags().StringVarP(&cfgPath, "config", "c", "", "config file path")
|
|
|
|
root.AddCommand(&cobra.Command{
|
|
Use: "version",
|
|
Short: "Print version",
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
fmt.Println(version)
|
|
},
|
|
})
|
|
|
|
if err := root.Execute(); err != nil {
|
|
os.Exit(1)
|
|
}
|
|
}
|