on main help sign in
fix(ui): don't show disabled skills
commit7a6149df39c1e2767d2f61e0e564007476b4bee8 authorBruno Krugel <brunokrugel@gmail.com> dateSat 25 Apr 2026, 16:12 (6 months ago) parentfa13c7f
1 file changed+15
internal/ui/model/skills.go+15
internal/ui/model/skills.go+15
@@ -58,6 +58,15 @@ func (m *UI) skillStatusItems() []skillStatusItem {
5858 var items []skillStatusItem
5959 stateNames := make(map[string]struct{}, len(m.skillStates))
6060
61+ disabledSet := make(map[string]bool)
62+ if m.com != nil && m.com.Workspace != nil {
63+ if cfg := m.com.Config(); cfg != nil {
64+ for _, name := range cfg.Options.DisabledSkills {
65+ disabledSet[name] = true
66+ }
67+ }
68+ }
69+
6170 states := slices.Clone(m.skillStates)
6271 slices.SortStableFunc(states, func(a, b *skills.SkillState) int {
6372 return strings.Compare(a.Path, b.Path)
@@ -67,6 +76,9 @@ func (m *UI) skillStatusItems() []skillStatusItem {
6776 if name == "" {
6877 name = filepath.Base(filepath.Dir(state.Path))
6978 }
79+ if disabledSet[name] {
80+ continue
81+ }
7082 stateNames[name] = struct{}{}
7183 icon := t.Resource.OnlineIcon.String()
7284 if state.State == skills.StateError {
@@ -87,6 +99,9 @@ func (m *UI) skillStatusItems() []skillStatusItem {
8799 if _, ok := stateNames[skill.Name]; ok {
88100 continue
89101 }
102+ if disabledSet[skill.Name] {
103+ continue
104+ }
90105 items = append(items, skillStatusItem{
91106 icon: t.Resource.OnlineIcon.String(),
92107 name: skill.Name,