Implement Milestone 1

This commit is contained in:
2025-10-09 19:19:31 -04:00
parent f7674cc2b0
commit 5e6ae2e429
12 changed files with 1671 additions and 5 deletions

33
cmd/onx/main.go Normal file
View File

@ -0,0 +1,33 @@
package main
import (
"fmt"
"os"
"git.dws.rip/DWS/onyx/internal/commands"
"github.com/spf13/cobra"
)
var version = "0.1.0"
func main() {
rootCmd := &cobra.Command{
Use: "onx",
Short: "Onyx - The iPhone of Version Control",
Long: `Onyx is a next-generation version control system that provides
a superior user experience layer on top of Git. It offers transparent
versioning, workstreams for stacked-diff management, and an action
log for universal undo functionality.`,
Version: version,
}
// Add commands
rootCmd.AddCommand(commands.NewInitCmd())
rootCmd.AddCommand(commands.NewUndoCmd())
// Execute the root command
if err := rootCmd.Execute(); err != nil {
fmt.Fprintf(os.Stderr, "Error: %v\n", err)
os.Exit(1)
}
}