@@ -59,6 +59,8 @@ If no agent is specified, skills are installed to .agent/skills/ by default.`,
5959 Run : runInstall ,
6060}
6161
62+ const maxInputLength = 255
63+
6264func runInstall (cmd * cobra.Command , args []string ) {
6365 // Check for offline mode
6466 if offline , _ := cmd .Flags ().GetBool ("offline" ); offline || github .OfflineMode {
@@ -103,6 +105,12 @@ func runInstall(cmd *cobra.Command, args []string) {
103105
104106 var expandedArgs []string
105107 for _ , input := range args {
108+ if len (input ) > maxInputLength {
109+ fmt .Printf ("Error: Input '%s...' is too long (max %d chars)\n " , input [:20 ], maxInputLength )
110+ failed = append (failed , input )
111+ continue
112+ }
113+
106114 // Check if input matches a configured repository name
107115 var targetRepo * config.Repo
108116 for i := range cfg .Repos {
@@ -576,6 +584,10 @@ func installSingleSkill(input string, global bool, agents []string, cfg *config.
576584 }
577585 }
578586
587+ if skillName == "" || strings .TrimSpace (skillName ) == "" {
588+ return fmt .Errorf ("could not determine skill name from input '%s'" , input )
589+ }
590+
579591 fmt .Printf ("Installing %s to %s...\n " , skillName , scopeLabel )
580592
581593 // Check if already installed in all targets
0 commit comments