- check CHANGELOG.md ver 0.2.1-alpha
This commit is contained in:
abelith committed 2026-08-14 19:14:18 +05:00
1 parent a8f164c241
commit 9434b02422
8 files changed
+59 -7

No files matched your search

+9 -1
View File
@@ -1,6 +1,10 @@
package cli
import "github.com/spf13/cobra"
import (
"fmt"
"github.com/abelith/spellbook/internal/errors"
"github.com/spf13/cobra"
)
func NewRmCommand(app Application) *cobra.Command {
cmd := &cobra.Command{
@@ -10,6 +14,10 @@ func NewRmCommand(app Application) *cobra.Command {
RunE: func(cmd *cobra.Command, args []string) error {
ctx := cmd.Context()
if len(args) < 1 {
return fmt.Errorf("%w: %s", errors.ErrInsufficientArgs, "spell_name")
}
return app.DeleteSpell(ctx, args[0])
},
}