mirror of
https://github.com/runkids/skillshare.git
synced 2026-11-20 20:34:19 +00:00
fix(sync): show duplicate skill names in collision message, fix vertical spacing
Display the actual duplicate skill name(s) in the "isolated by target filters" info message so users can identify which skills collide. Remove the extra fmt.Println() before backup section — ui.Header() already includes a leading newline, so the previous blank line created a double gap. Also replace VirtualizedGroupedView with native DOM GroupedView using sticky sub-headers that respect the toolbar height offset.
This commit is contained in:
@@ -169,7 +169,6 @@ func cmdSync(args []string) error {
|
||||
|
||||
// Backup targets before sync (only if not dry-run and there are skills)
|
||||
if !dryRun && len(discoveredSkills) > 0 && !jsonOutput {
|
||||
fmt.Println()
|
||||
backupTargetsBeforeSync(cfg)
|
||||
}
|
||||
|
||||
@@ -568,8 +567,12 @@ func reportCollisions(skills []sync.DiscoveredSkill, targets map[string]config.T
|
||||
fmt.Println()
|
||||
} else {
|
||||
// Global collision exists but filters isolate them — single summary line
|
||||
names := make([]string, len(global))
|
||||
for i, c := range global {
|
||||
names[i] = c.Name
|
||||
}
|
||||
fmt.Println()
|
||||
ui.Info("%d duplicate skill names (isolated by target filters)", len(global))
|
||||
ui.Info("%d duplicate skill names (isolated by target filters): %s", len(global), strings.Join(names, ", "))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user