claudeup 4.19.0 → 4.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/claudeup.js +43 -19
- package/package.json +14 -19
- package/scripts/build-binaries.ts +77 -0
- package/scripts/check-optional-deps.ts +49 -0
- package/scripts/test-isolated.ts +43 -0
- package/src/__tests__/cli-router.test.ts +65 -0
- package/src/__tests__/conventions-integration.test.ts +745 -0
- package/src/__tests__/conventions-manager.test.ts +1172 -0
- package/src/__tests__/doctor-bins.test.ts +35 -0
- package/src/__tests__/doctor.test.ts +450 -0
- package/src/__tests__/dual-write-prevention.test.ts +14 -4
- package/src/__tests__/file-locking.test.ts +208 -0
- package/src/__tests__/gitignore-prerun.test.ts +1 -0
- package/src/__tests__/install-command.test.ts +81 -0
- package/src/__tests__/install-plan.test.ts +98 -0
- package/src/__tests__/manifest.test.ts +136 -0
- package/src/__tests__/marketplace-refresh.test.ts +267 -0
- package/src/__tests__/plugin-requires.test.ts +133 -0
- package/src/__tests__/plugin-setup.test.ts +7 -0
- package/src/__tests__/profile-command.test.ts +116 -0
- package/src/__tests__/profile-materializer.test.ts +82 -0
- package/src/__tests__/profile-sync.test.ts +136 -0
- package/src/__tests__/registry-version-resolution.test.ts +74 -0
- package/src/__tests__/resolve-executable.test.ts +42 -0
- package/src/__tests__/resolver.test.ts +218 -0
- package/src/__tests__/symlink-manager.test.ts +99 -0
- package/src/__tests__/toolchain.test.ts +56 -0
- package/src/cli/claude.ts +21 -0
- package/src/cli/doctor.ts +132 -0
- package/src/cli/install.ts +360 -0
- package/src/cli/profile.ts +166 -0
- package/src/cli/router.ts +107 -0
- package/src/cli/update.ts +85 -0
- package/src/data/cli-tools.ts +7 -7
- package/src/data/gitignore-defaults.ts +4 -0
- package/src/data/marketplaces.ts +12 -0
- package/src/data/predefined-profiles.ts +3 -4
- package/src/main.tsx +11 -154
- package/src/prerunner/index.ts +62 -27
- package/src/services/claude-cli.ts +19 -22
- package/src/services/claude-settings.ts +99 -26
- package/src/services/conventions-manager.ts +865 -0
- package/src/services/doctor-bins.ts +49 -0
- package/src/services/doctor.ts +509 -0
- package/src/services/install-plan.ts +107 -0
- package/src/services/manifest.ts +166 -0
- package/src/services/marketplace-refresh.ts +173 -0
- package/src/services/plugin-manager.ts +7 -1
- package/src/services/plugin-requires.ts +215 -0
- package/src/services/plugin-version-check.ts +9 -4
- package/src/services/profile-materializer.ts +61 -0
- package/src/services/profile-sync.ts +150 -0
- package/src/services/resolver.ts +293 -0
- package/src/services/symlink-manager.ts +146 -0
- package/src/services/toolchain.ts +97 -0
- package/src/services/version-check.ts +10 -11
- package/src/types/index.ts +138 -31
- package/src/ui/App.tsx +0 -4
- package/src/ui/screens/CliToolsScreen.tsx +11 -3
- package/src/ui/screens/index.ts +0 -1
- package/src/ui/state/reducer.ts +0 -101
- package/src/ui/state/types.ts +0 -35
- package/src/utils/command-utils.ts +23 -0
- package/src/utils/file-locking.ts +144 -0
- package/src/data/alias-flags.js +0 -205
- package/src/data/cli-tools.js +0 -123
- package/src/data/gitignore-defaults.js +0 -24
- package/src/data/gitignore-reasons.js +0 -97
- package/src/data/gitignore-templates.js +0 -21
- package/src/data/marketplaces.js +0 -138
- package/src/data/mcp-servers.js +0 -509
- package/src/data/predefined-profiles.js +0 -248
- package/src/data/settings-catalog.js +0 -625
- package/src/data/skill-repos.js +0 -160
- package/src/data/statuslines.js +0 -159
- package/src/data/statuslines.ts +0 -188
- package/src/index.js +0 -4
- package/src/index.ts +0 -5
- package/src/main.js +0 -170
- package/src/prerunner/index.js +0 -252
- package/src/services/alias-settings.js +0 -51
- package/src/services/alias-shell-writer.js +0 -1018
- package/src/services/alias-store.js +0 -129
- package/src/services/claude-cli.js +0 -189
- package/src/services/claude-runner.js +0 -28
- package/src/services/claude-settings.js +0 -1223
- package/src/services/gitignore-detector.js +0 -155
- package/src/services/gitignore-fixer.js +0 -231
- package/src/services/gitignore-prerun.js +0 -46
- package/src/services/gitignore-resolver.js +0 -143
- package/src/services/gitignore-service.js +0 -117
- package/src/services/local-marketplace.js +0 -339
- package/src/services/marketplace-fetcher.js +0 -96
- package/src/services/marketplace-sync.js +0 -94
- package/src/services/mcp-registry.js +0 -87
- package/src/services/plugin-manager.js +0 -473
- package/src/services/plugin-mcp-config.js +0 -177
- package/src/services/plugin-setup.js +0 -499
- package/src/services/plugin-version-check.js +0 -262
- package/src/services/profiles.js +0 -161
- package/src/services/settings-manager.js +0 -243
- package/src/services/skills-manager.js +0 -393
- package/src/services/skillsmp-client.js +0 -87
- package/src/services/update-cache.js +0 -52
- package/src/services/version-check.js +0 -99
- package/src/types/gitignore.js +0 -6
- package/src/types/index.js +0 -1
- package/src/ui/App.js +0 -355
- package/src/ui/adapters/pluginsAdapter.js +0 -139
- package/src/ui/adapters/settingsAdapter.js +0 -111
- package/src/ui/adapters/skillsAdapter.js +0 -154
- package/src/ui/components/CategoryHeader.js +0 -9
- package/src/ui/components/EmptyFilterState.js +0 -4
- package/src/ui/components/FlagDetailEditor.js +0 -0
- package/src/ui/components/ScopeIndicator.js +0 -30
- package/src/ui/components/ScrollableList.js +0 -36
- package/src/ui/components/SearchInput.js +0 -19
- package/src/ui/components/StyledText.js +0 -39
- package/src/ui/components/TabBar.js +0 -19
- package/src/ui/components/layout/FooterHints.js +0 -29
- package/src/ui/components/layout/Panel.js +0 -6
- package/src/ui/components/layout/ProgressBar.js +0 -14
- package/src/ui/components/layout/ScopeTabs.js +0 -6
- package/src/ui/components/layout/ScreenLayout.js +0 -16
- package/src/ui/components/layout/index.js +0 -5
- package/src/ui/components/modals/ConfirmModal.js +0 -14
- package/src/ui/components/modals/InputModal.js +0 -5
- package/src/ui/components/modals/LoadingModal.js +0 -17
- package/src/ui/components/modals/MessageModal.js +0 -16
- package/src/ui/components/modals/ModalContainer.js +0 -137
- package/src/ui/components/modals/SelectModal.js +0 -18
- package/src/ui/components/modals/VersionMismatchModal.js +0 -36
- package/src/ui/components/modals/index.js +0 -6
- package/src/ui/components/primitives/ActionHints.js +0 -13
- package/src/ui/components/primitives/DetailSection.js +0 -7
- package/src/ui/components/primitives/KeyValueLine.js +0 -8
- package/src/ui/components/primitives/ListCategoryRow.js +0 -8
- package/src/ui/components/primitives/MetaText.js +0 -8
- package/src/ui/components/primitives/ScopeDetail.js +0 -32
- package/src/ui/components/primitives/ScopeSquares.js +0 -11
- package/src/ui/components/primitives/SelectableRow.js +0 -5
- package/src/ui/components/primitives/index.js +0 -8
- package/src/ui/hooks/index.js +0 -4
- package/src/ui/hooks/useAsyncData.js +0 -77
- package/src/ui/hooks/useGitignoreModal.js +0 -74
- package/src/ui/hooks/useKeyboard.js +0 -13
- package/src/ui/hooks/useKeyboardHandler.js +0 -39
- package/src/ui/hooks/useMismatchModal.js +0 -77
- package/src/ui/registry.js +0 -1
- package/src/ui/renderers/cliToolRenderers.js +0 -54
- package/src/ui/renderers/gitignoreRenderers.js +0 -46
- package/src/ui/renderers/mcpRenderers.js +0 -26
- package/src/ui/renderers/pluginRenderers.js +0 -124
- package/src/ui/renderers/profileRenderers.js +0 -177
- package/src/ui/renderers/settingsRenderers.js +0 -73
- package/src/ui/renderers/skillRenderers.js +0 -138
- package/src/ui/screens/AliasScreen.js +0 -1111
- package/src/ui/screens/CliToolsScreen.js +0 -338
- package/src/ui/screens/EnvVarsScreen.js +0 -152
- package/src/ui/screens/GitignoreScreen.js +0 -328
- package/src/ui/screens/McpRegistryScreen.js +0 -238
- package/src/ui/screens/McpScreen.js +0 -176
- package/src/ui/screens/ModelSelectorScreen.js +0 -296
- package/src/ui/screens/ModelSelectorScreen.tsx +0 -444
- package/src/ui/screens/PluginsScreen.js +0 -769
- package/src/ui/screens/ProfilesScreen.js +0 -298
- package/src/ui/screens/SkillsScreen.js +0 -549
- package/src/ui/screens/StatusLineScreen.js +0 -206
- package/src/ui/screens/StatusLineScreen.tsx +0 -416
- package/src/ui/screens/index.js +0 -10
- package/src/ui/state/AnimationContext.js +0 -34
- package/src/ui/state/AppContext.js +0 -162
- package/src/ui/state/DimensionsContext.js +0 -71
- package/src/ui/state/reducer.js +0 -547
- package/src/ui/state/types.js +0 -1
- package/src/ui/theme.js +0 -47
- package/src/utils/clipboard.js +0 -56
- package/src/utils/command-utils.js +0 -19
- package/src/utils/fuzzy-search.js +0 -101
- package/src/utils/string-utils.js +0 -62
package/src/data/skill-repos.js
DELETED
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
export const RECOMMENDED_SKILLS = [
|
|
2
|
-
{
|
|
3
|
-
name: "Find Skills",
|
|
4
|
-
repo: "vercel-labs/skills",
|
|
5
|
-
skillPath: "skills/find-skills",
|
|
6
|
-
description: "Discover and install new skills from the ecosystem",
|
|
7
|
-
category: "search",
|
|
8
|
-
stars: 12000,
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
name: "React Best Practices",
|
|
12
|
-
repo: "vercel-labs/agent-skills",
|
|
13
|
-
skillPath: "skills/react-best-practices",
|
|
14
|
-
description: "Modern React patterns and Vercel deployment guidelines",
|
|
15
|
-
category: "frontend",
|
|
16
|
-
stars: 24000,
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
name: "Web Design Guidelines",
|
|
20
|
-
repo: "vercel-labs/agent-skills",
|
|
21
|
-
skillPath: "skills/web-design-guidelines",
|
|
22
|
-
description: "UI/UX design principles and web standards",
|
|
23
|
-
category: "design",
|
|
24
|
-
stars: 24000,
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
name: "Remotion Best Practices",
|
|
28
|
-
repo: "remotion-dev/skills",
|
|
29
|
-
skillPath: "skills/remotion-best-practices",
|
|
30
|
-
description: "Programmatic video creation with Remotion",
|
|
31
|
-
category: "media",
|
|
32
|
-
stars: 2400,
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
name: "UI/UX Pro Max",
|
|
36
|
-
repo: "jh941213/my-claude-code-asset",
|
|
37
|
-
skillPath: "skills_en/ui-ux-pro-max",
|
|
38
|
-
description: "50 styles, 21 palettes, 50 font pairings, 9 stacks. Covers React, Next.js, Vue, Svelte, SwiftUI, Flutter, Tailwind, shadcn/ui",
|
|
39
|
-
category: "design",
|
|
40
|
-
stars: 109,
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
name: "ElevenLabs TTS",
|
|
44
|
-
repo: "inferen-sh/skills",
|
|
45
|
-
skillPath: "skills/elevenlabs-tts",
|
|
46
|
-
description: "Text-to-speech with ElevenLabs API integration",
|
|
47
|
-
category: "media",
|
|
48
|
-
stars: 206,
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
name: "Audit Website",
|
|
52
|
-
repo: "squirrelscan/skills",
|
|
53
|
-
skillPath: "skills/audit-website",
|
|
54
|
-
description: "Security and quality auditing for web applications",
|
|
55
|
-
category: "security",
|
|
56
|
-
stars: 67,
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
name: "Systematic Debugging",
|
|
60
|
-
repo: "obra/superpowers",
|
|
61
|
-
skillPath: "skills/systematic-debugging",
|
|
62
|
-
description: "Structured debugging methodology with root cause analysis",
|
|
63
|
-
category: "debugging",
|
|
64
|
-
stars: 113000,
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
name: "shadcn/ui",
|
|
68
|
-
repo: "shadcn-ui/ui",
|
|
69
|
-
skillPath: "packages/shadcn",
|
|
70
|
-
description: "shadcn/ui component library patterns and usage",
|
|
71
|
-
category: "frontend",
|
|
72
|
-
stars: 111000,
|
|
73
|
-
},
|
|
74
|
-
{
|
|
75
|
-
name: "Neon Postgres",
|
|
76
|
-
repo: "neondatabase/agent-skills",
|
|
77
|
-
skillPath: "skills/neon-postgres",
|
|
78
|
-
description: "Neon serverless Postgres setup and best practices",
|
|
79
|
-
category: "database",
|
|
80
|
-
stars: 42,
|
|
81
|
-
},
|
|
82
|
-
{
|
|
83
|
-
name: "Neon Serverless",
|
|
84
|
-
repo: "neondatabase/ai-rules",
|
|
85
|
-
skillPath: "skills/neon-serverless",
|
|
86
|
-
description: "Serverless database patterns with Neon",
|
|
87
|
-
category: "database",
|
|
88
|
-
stars: 81,
|
|
89
|
-
},
|
|
90
|
-
];
|
|
91
|
-
export const RECOMMENDED_SKILL_SETS = [
|
|
92
|
-
{
|
|
93
|
-
name: "Hugging Face",
|
|
94
|
-
repo: "huggingface/skills",
|
|
95
|
-
description: "Give your agents the power of the Hugging Face ecosystem",
|
|
96
|
-
icon: "\u{1F917}",
|
|
97
|
-
stars: 10000,
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
name: "Browserbase",
|
|
101
|
-
repo: "browserbase/skills",
|
|
102
|
-
description: "Web browsing, UI testing, and browser automation via the Claude Agent SDK",
|
|
103
|
-
icon: "\u{1F310}",
|
|
104
|
-
stars: 521,
|
|
105
|
-
},
|
|
106
|
-
];
|
|
107
|
-
// ─── Star reliability classification ────────────────────────────────────────
|
|
108
|
-
// Stars from these repos don't reflect individual skill quality.
|
|
109
|
-
/** Mega-repos: huge projects that happen to include skills. Stars are about the project. */
|
|
110
|
-
const MEGA_REPOS = new Set([
|
|
111
|
-
"microsoft/vscode",
|
|
112
|
-
"Significant-Gravitas/AutoGPT",
|
|
113
|
-
"n8n-io/n8n",
|
|
114
|
-
"anomalyco/opencode",
|
|
115
|
-
"shadcn-ui/ui",
|
|
116
|
-
]);
|
|
117
|
-
/** Skill-dump repos: large collections where stars reflect quantity, not quality. */
|
|
118
|
-
const SKILL_DUMP_REPOS = new Set([
|
|
119
|
-
"affaan-m/everything-claude-code",
|
|
120
|
-
"openclaw/openclaw",
|
|
121
|
-
"jh941213/my-claude-code-asset",
|
|
122
|
-
"inferen-sh/skills",
|
|
123
|
-
]);
|
|
124
|
-
/**
|
|
125
|
-
* Classify how reliable a repo's star count is as a quality signal for its skills.
|
|
126
|
-
* - "dedicated": Stars reflect skill/repo quality (e.g. huggingface/skills, vercel-labs/agent-skills)
|
|
127
|
-
* - "mega-repo": Stars are about a larger project, not the skills (e.g. microsoft/vscode)
|
|
128
|
-
* - "skill-dump": Large skill collection — stars reflect popularity/quantity, not individual quality
|
|
129
|
-
*/
|
|
130
|
-
export function classifyStarReliability(repo, stars) {
|
|
131
|
-
if (MEGA_REPOS.has(repo))
|
|
132
|
-
return "mega-repo";
|
|
133
|
-
if (SKILL_DUMP_REPOS.has(repo))
|
|
134
|
-
return "skill-dump";
|
|
135
|
-
// Heuristic: unknown repos with >50K stars are likely mega-repos
|
|
136
|
-
if (stars && stars > 50000)
|
|
137
|
-
return "mega-repo";
|
|
138
|
-
return "dedicated";
|
|
139
|
-
}
|
|
140
|
-
export const STAR_RELIABILITY_INFO = {
|
|
141
|
-
dedicated: {
|
|
142
|
-
label: "Skill repo",
|
|
143
|
-
description: "Stars reflect this skill repository's quality",
|
|
144
|
-
},
|
|
145
|
-
"mega-repo": {
|
|
146
|
-
label: "Project repo",
|
|
147
|
-
description: "Stars are for the parent project, not the skills. Skill quality may vary.",
|
|
148
|
-
},
|
|
149
|
-
"skill-dump": {
|
|
150
|
-
label: "Skill collection",
|
|
151
|
-
description: "Large skill collection — stars reflect repo popularity, not individual skill quality.",
|
|
152
|
-
},
|
|
153
|
-
};
|
|
154
|
-
export const DEFAULT_SKILL_REPOS = [
|
|
155
|
-
{
|
|
156
|
-
label: "Vercel Agent Skills",
|
|
157
|
-
repo: "vercel-labs/agent-skills",
|
|
158
|
-
skillsPath: "skills",
|
|
159
|
-
},
|
|
160
|
-
];
|
package/src/data/statuslines.js
DELETED
|
@@ -1,159 +0,0 @@
|
|
|
1
|
-
export const statusLineCategories = [
|
|
2
|
-
{
|
|
3
|
-
name: "🎨 Color Themes",
|
|
4
|
-
color: "magenta",
|
|
5
|
-
presets: [
|
|
6
|
-
{
|
|
7
|
-
name: "🌸 Catppuccin",
|
|
8
|
-
description: "Soothing pastel (most popular 2024)",
|
|
9
|
-
template: "* {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
10
|
-
},
|
|
11
|
-
{
|
|
12
|
-
name: "🧛 Dracula",
|
|
13
|
-
description: "Classic dark with purple vibes",
|
|
14
|
-
template: "{model} > {git_branch} > {input_tokens}v {output_tokens}^ > ${cost} > {cwd}",
|
|
15
|
-
},
|
|
16
|
-
{
|
|
17
|
-
name: "❄️ Nord",
|
|
18
|
-
description: "Arctic, bluish & clean",
|
|
19
|
-
template: "~ {model} | {git_branch} | {input_tokens}< {output_tokens}> | ${cost} | {cwd}",
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
name: "🍂 Gruvbox",
|
|
23
|
-
description: "Warm retro terminal feel",
|
|
24
|
-
template: ">> {model} :: {git_branch} :: {input_tokens}v {output_tokens}^ :: ${cost} :: {cwd}",
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
name: "🌃 Tokyo Night",
|
|
28
|
-
description: "Neon city vibes",
|
|
29
|
-
template: "> {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
name: "🌹 Rose Pine",
|
|
33
|
-
description: "Soft, romantic & elegant",
|
|
34
|
-
template: "@ {model} : {git_branch} : {input_tokens}v {output_tokens}^ : ${cost} : {cwd}",
|
|
35
|
-
},
|
|
36
|
-
],
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
name: "🚀 Shell Prompts",
|
|
40
|
-
color: "cyan",
|
|
41
|
-
presets: [
|
|
42
|
-
{
|
|
43
|
-
name: "⭐ Starship",
|
|
44
|
-
description: "Blazing fast, minimal & smart",
|
|
45
|
-
template: "-> {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
46
|
-
},
|
|
47
|
-
{
|
|
48
|
-
name: "⚡ Powerline",
|
|
49
|
-
description: "Classic powerline segments",
|
|
50
|
-
template: "{model} > {git_branch} > {input_tokens}v {output_tokens}^ > ${cost} > {cwd}",
|
|
51
|
-
},
|
|
52
|
-
],
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
name: "💻 Developer",
|
|
56
|
-
color: "green",
|
|
57
|
-
presets: [
|
|
58
|
-
{
|
|
59
|
-
name: "🖥️ Hacker",
|
|
60
|
-
description: "Matrix-inspired with all metrics",
|
|
61
|
-
template: "[{model}] [{git_branch}] [v{input_tokens} ^{output_tokens}] [${cost}] [{cwd}]",
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
name: "🔧 DevOps",
|
|
65
|
-
description: "Infrastructure-focused",
|
|
66
|
-
template: "# {model} | {git_branch} | {input_tokens}/{output_tokens} | ${cost} | {cwd}",
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
name: "📊 Metrics",
|
|
70
|
-
description: "Data-focused with stats",
|
|
71
|
-
template: "* {model} | {session_duration} | v{input_tokens} ^{output_tokens} | ${cost}",
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
name: "🌿 Git First",
|
|
75
|
-
description: "Branch name prominent",
|
|
76
|
-
template: "[{git_branch}] {model} | ${cost} | {cwd}",
|
|
77
|
-
},
|
|
78
|
-
],
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
name: "✨ Minimal",
|
|
82
|
-
color: "white",
|
|
83
|
-
presets: [
|
|
84
|
-
{
|
|
85
|
-
name: "🧘 Zen",
|
|
86
|
-
description: "Minimalist & distraction-free",
|
|
87
|
-
template: "{model_short} - ${cost}",
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
name: "💎 Clean",
|
|
91
|
-
description: "Simple & elegant",
|
|
92
|
-
template: "{model} -- ${cost} -- {cwd}",
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
name: "➡️ Arrow",
|
|
96
|
-
description: "Compact with direction",
|
|
97
|
-
template: "> {model} > ${cost} > {git_branch}",
|
|
98
|
-
},
|
|
99
|
-
],
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
name: "🎮 Fun",
|
|
103
|
-
color: "yellow",
|
|
104
|
-
presets: [
|
|
105
|
-
{
|
|
106
|
-
name: "👾 Retro",
|
|
107
|
-
description: "8-bit gaming aesthetic",
|
|
108
|
-
template: "[ {model} ] * {git_branch} * v{input_tokens} ^{output_tokens} * ${cost}",
|
|
109
|
-
},
|
|
110
|
-
{
|
|
111
|
-
name: "📦 Brackets",
|
|
112
|
-
description: "Everything in brackets",
|
|
113
|
-
template: "[{model}] [{git_branch}] [in:{input_tokens}] [out:{output_tokens}] [${cost}] [{cwd}]",
|
|
114
|
-
},
|
|
115
|
-
{
|
|
116
|
-
name: "🔀 Pipes",
|
|
117
|
-
description: "Unix pipe style",
|
|
118
|
-
template: "{model} | {git_branch} | in:{input_tokens} out:{output_tokens} | ${cost} | {cwd}",
|
|
119
|
-
},
|
|
120
|
-
],
|
|
121
|
-
},
|
|
122
|
-
{
|
|
123
|
-
name: "📱 Compact",
|
|
124
|
-
color: "blue",
|
|
125
|
-
presets: [
|
|
126
|
-
{
|
|
127
|
-
name: "🔬 Micro",
|
|
128
|
-
description: "Ultra-compact essentials",
|
|
129
|
-
template: "{model_short} ${cost}",
|
|
130
|
-
},
|
|
131
|
-
{
|
|
132
|
-
name: "〉Chevron",
|
|
133
|
-
description: "Chevron separators",
|
|
134
|
-
template: "{model_short} > ${cost} > {git_branch}",
|
|
135
|
-
},
|
|
136
|
-
],
|
|
137
|
-
},
|
|
138
|
-
{
|
|
139
|
-
name: "⏱️ Time",
|
|
140
|
-
color: "red",
|
|
141
|
-
presets: [
|
|
142
|
-
{
|
|
143
|
-
name: "⏰ Timer",
|
|
144
|
-
description: "Session time focused",
|
|
145
|
-
template: "[{session_duration}] {model} | v{input_tokens} ^{output_tokens} | ${cost}",
|
|
146
|
-
},
|
|
147
|
-
{
|
|
148
|
-
name: "📅 Session",
|
|
149
|
-
description: "Full session overview",
|
|
150
|
-
template: "{model} | {session_duration} | {input_tokens}/{output_tokens} | ${cost} | {cwd}",
|
|
151
|
-
},
|
|
152
|
-
],
|
|
153
|
-
},
|
|
154
|
-
];
|
|
155
|
-
// Flatten for backward compatibility
|
|
156
|
-
export const statusLinePresets = statusLineCategories.flatMap((cat) => cat.presets);
|
|
157
|
-
export function getStatusLineByName(name) {
|
|
158
|
-
return statusLinePresets.find((s) => s.name === name);
|
|
159
|
-
}
|
package/src/data/statuslines.ts
DELETED
|
@@ -1,188 +0,0 @@
|
|
|
1
|
-
import type { StatusLineConfig } from "../types/index.js";
|
|
2
|
-
|
|
3
|
-
export interface StatusLineCategory {
|
|
4
|
-
name: string;
|
|
5
|
-
color: string;
|
|
6
|
-
presets: StatusLineConfig[];
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
export const statusLineCategories: StatusLineCategory[] = [
|
|
10
|
-
{
|
|
11
|
-
name: "🎨 Color Themes",
|
|
12
|
-
color: "magenta",
|
|
13
|
-
presets: [
|
|
14
|
-
{
|
|
15
|
-
name: "🌸 Catppuccin",
|
|
16
|
-
description: "Soothing pastel (most popular 2024)",
|
|
17
|
-
template:
|
|
18
|
-
"* {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
name: "🧛 Dracula",
|
|
22
|
-
description: "Classic dark with purple vibes",
|
|
23
|
-
template:
|
|
24
|
-
"{model} > {git_branch} > {input_tokens}v {output_tokens}^ > ${cost} > {cwd}",
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
name: "❄️ Nord",
|
|
28
|
-
description: "Arctic, bluish & clean",
|
|
29
|
-
template:
|
|
30
|
-
"~ {model} | {git_branch} | {input_tokens}< {output_tokens}> | ${cost} | {cwd}",
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
name: "🍂 Gruvbox",
|
|
34
|
-
description: "Warm retro terminal feel",
|
|
35
|
-
template:
|
|
36
|
-
">> {model} :: {git_branch} :: {input_tokens}v {output_tokens}^ :: ${cost} :: {cwd}",
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
name: "🌃 Tokyo Night",
|
|
40
|
-
description: "Neon city vibes",
|
|
41
|
-
template:
|
|
42
|
-
"> {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
name: "🌹 Rose Pine",
|
|
46
|
-
description: "Soft, romantic & elegant",
|
|
47
|
-
template:
|
|
48
|
-
"@ {model} : {git_branch} : {input_tokens}v {output_tokens}^ : ${cost} : {cwd}",
|
|
49
|
-
},
|
|
50
|
-
],
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
name: "🚀 Shell Prompts",
|
|
54
|
-
color: "cyan",
|
|
55
|
-
presets: [
|
|
56
|
-
{
|
|
57
|
-
name: "⭐ Starship",
|
|
58
|
-
description: "Blazing fast, minimal & smart",
|
|
59
|
-
template:
|
|
60
|
-
"-> {model} | {git_branch} | {input_tokens}v {output_tokens}^ | ${cost} | {cwd}",
|
|
61
|
-
},
|
|
62
|
-
{
|
|
63
|
-
name: "⚡ Powerline",
|
|
64
|
-
description: "Classic powerline segments",
|
|
65
|
-
template:
|
|
66
|
-
"{model} > {git_branch} > {input_tokens}v {output_tokens}^ > ${cost} > {cwd}",
|
|
67
|
-
},
|
|
68
|
-
],
|
|
69
|
-
},
|
|
70
|
-
{
|
|
71
|
-
name: "💻 Developer",
|
|
72
|
-
color: "green",
|
|
73
|
-
presets: [
|
|
74
|
-
{
|
|
75
|
-
name: "🖥️ Hacker",
|
|
76
|
-
description: "Matrix-inspired with all metrics",
|
|
77
|
-
template:
|
|
78
|
-
"[{model}] [{git_branch}] [v{input_tokens} ^{output_tokens}] [${cost}] [{cwd}]",
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
name: "🔧 DevOps",
|
|
82
|
-
description: "Infrastructure-focused",
|
|
83
|
-
template:
|
|
84
|
-
"# {model} | {git_branch} | {input_tokens}/{output_tokens} | ${cost} | {cwd}",
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
name: "📊 Metrics",
|
|
88
|
-
description: "Data-focused with stats",
|
|
89
|
-
template:
|
|
90
|
-
"* {model} | {session_duration} | v{input_tokens} ^{output_tokens} | ${cost}",
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
name: "🌿 Git First",
|
|
94
|
-
description: "Branch name prominent",
|
|
95
|
-
template: "[{git_branch}] {model} | ${cost} | {cwd}",
|
|
96
|
-
},
|
|
97
|
-
],
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
name: "✨ Minimal",
|
|
101
|
-
color: "white",
|
|
102
|
-
presets: [
|
|
103
|
-
{
|
|
104
|
-
name: "🧘 Zen",
|
|
105
|
-
description: "Minimalist & distraction-free",
|
|
106
|
-
template: "{model_short} - ${cost}",
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
name: "💎 Clean",
|
|
110
|
-
description: "Simple & elegant",
|
|
111
|
-
template: "{model} -- ${cost} -- {cwd}",
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
name: "➡️ Arrow",
|
|
115
|
-
description: "Compact with direction",
|
|
116
|
-
template: "> {model} > ${cost} > {git_branch}",
|
|
117
|
-
},
|
|
118
|
-
],
|
|
119
|
-
},
|
|
120
|
-
{
|
|
121
|
-
name: "🎮 Fun",
|
|
122
|
-
color: "yellow",
|
|
123
|
-
presets: [
|
|
124
|
-
{
|
|
125
|
-
name: "👾 Retro",
|
|
126
|
-
description: "8-bit gaming aesthetic",
|
|
127
|
-
template:
|
|
128
|
-
"[ {model} ] * {git_branch} * v{input_tokens} ^{output_tokens} * ${cost}",
|
|
129
|
-
},
|
|
130
|
-
{
|
|
131
|
-
name: "📦 Brackets",
|
|
132
|
-
description: "Everything in brackets",
|
|
133
|
-
template:
|
|
134
|
-
"[{model}] [{git_branch}] [in:{input_tokens}] [out:{output_tokens}] [${cost}] [{cwd}]",
|
|
135
|
-
},
|
|
136
|
-
{
|
|
137
|
-
name: "🔀 Pipes",
|
|
138
|
-
description: "Unix pipe style",
|
|
139
|
-
template:
|
|
140
|
-
"{model} | {git_branch} | in:{input_tokens} out:{output_tokens} | ${cost} | {cwd}",
|
|
141
|
-
},
|
|
142
|
-
],
|
|
143
|
-
},
|
|
144
|
-
{
|
|
145
|
-
name: "📱 Compact",
|
|
146
|
-
color: "blue",
|
|
147
|
-
presets: [
|
|
148
|
-
{
|
|
149
|
-
name: "🔬 Micro",
|
|
150
|
-
description: "Ultra-compact essentials",
|
|
151
|
-
template: "{model_short} ${cost}",
|
|
152
|
-
},
|
|
153
|
-
{
|
|
154
|
-
name: "〉Chevron",
|
|
155
|
-
description: "Chevron separators",
|
|
156
|
-
template: "{model_short} > ${cost} > {git_branch}",
|
|
157
|
-
},
|
|
158
|
-
],
|
|
159
|
-
},
|
|
160
|
-
{
|
|
161
|
-
name: "⏱️ Time",
|
|
162
|
-
color: "red",
|
|
163
|
-
presets: [
|
|
164
|
-
{
|
|
165
|
-
name: "⏰ Timer",
|
|
166
|
-
description: "Session time focused",
|
|
167
|
-
template:
|
|
168
|
-
"[{session_duration}] {model} | v{input_tokens} ^{output_tokens} | ${cost}",
|
|
169
|
-
},
|
|
170
|
-
{
|
|
171
|
-
name: "📅 Session",
|
|
172
|
-
description: "Full session overview",
|
|
173
|
-
template:
|
|
174
|
-
"{model} | {session_duration} | {input_tokens}/{output_tokens} | ${cost} | {cwd}",
|
|
175
|
-
},
|
|
176
|
-
],
|
|
177
|
-
},
|
|
178
|
-
];
|
|
179
|
-
|
|
180
|
-
// Flatten for backward compatibility
|
|
181
|
-
export const statusLinePresets: StatusLineConfig[] =
|
|
182
|
-
statusLineCategories.flatMap((cat) => cat.presets);
|
|
183
|
-
|
|
184
|
-
export function getStatusLineByName(
|
|
185
|
-
name: string,
|
|
186
|
-
): StatusLineConfig | undefined {
|
|
187
|
-
return statusLinePresets.find((s) => s.name === name);
|
|
188
|
-
}
|
package/src/index.js
DELETED
package/src/index.ts
DELETED
package/src/main.js
DELETED
|
@@ -1,170 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env bun
|
|
2
|
-
import { jsx as _jsx } from "@opentui/react/jsx-runtime";
|
|
3
|
-
import { createCliRenderer } from "@opentui/core";
|
|
4
|
-
import { createRoot } from "@opentui/react";
|
|
5
|
-
import { spawn } from "node:child_process";
|
|
6
|
-
import { createRequire } from "node:module";
|
|
7
|
-
import { App } from "./ui/App.js";
|
|
8
|
-
import { prerunClaude } from "./prerunner/index.js";
|
|
9
|
-
import { checkForUpdates } from "./services/version-check.js";
|
|
10
|
-
const require = createRequire(import.meta.url);
|
|
11
|
-
const pkg = require("../package.json");
|
|
12
|
-
export const VERSION = pkg.version;
|
|
13
|
-
// Note: OpenTUI renderer handles alternate screen buffer automatically
|
|
14
|
-
// No need for manual ANSI escape codes
|
|
15
|
-
async function main() {
|
|
16
|
-
const args = process.argv.slice(2);
|
|
17
|
-
// Handle "claudeup claude [args]" - prerunner mode
|
|
18
|
-
if (args[0] === "claude") {
|
|
19
|
-
const claudeArgs = args.slice(1);
|
|
20
|
-
// Parse prerunner-specific flags
|
|
21
|
-
const forceUpdate = claudeArgs.includes("--force") || claudeArgs.includes("-f");
|
|
22
|
-
// Remove prerunner flags before passing to claude
|
|
23
|
-
const filteredArgs = claudeArgs.filter((arg) => arg !== "--force" && arg !== "-f");
|
|
24
|
-
const exitCode = await prerunClaude(filteredArgs, { force: forceUpdate });
|
|
25
|
-
process.exit(exitCode);
|
|
26
|
-
return;
|
|
27
|
-
}
|
|
28
|
-
// Handle "claudeup update" - self-update command
|
|
29
|
-
if (args[0] === "update") {
|
|
30
|
-
const { execSync } = await import("node:child_process");
|
|
31
|
-
const { existsSync } = await import("node:fs");
|
|
32
|
-
// Detect all installations of claudeup across package managers
|
|
33
|
-
const installations = [];
|
|
34
|
-
// Check bun global
|
|
35
|
-
try {
|
|
36
|
-
const bunGlobalBin = execSync("bun pm -g bin", {
|
|
37
|
-
encoding: "utf-8",
|
|
38
|
-
timeout: 5000,
|
|
39
|
-
}).trim();
|
|
40
|
-
const bunPath = `${bunGlobalBin}/claudeup`;
|
|
41
|
-
if (existsSync(bunPath))
|
|
42
|
-
installations.push({ manager: "bun", path: bunPath });
|
|
43
|
-
}
|
|
44
|
-
catch {
|
|
45
|
-
// bun not installed or no global claudeup
|
|
46
|
-
}
|
|
47
|
-
// Check npm global
|
|
48
|
-
try {
|
|
49
|
-
const npmPrefix = execSync("npm prefix -g", {
|
|
50
|
-
encoding: "utf-8",
|
|
51
|
-
timeout: 5000,
|
|
52
|
-
}).trim();
|
|
53
|
-
const npmPath = `${npmPrefix}/bin/claudeup`;
|
|
54
|
-
if (existsSync(npmPath))
|
|
55
|
-
installations.push({ manager: "npm", path: npmPath });
|
|
56
|
-
}
|
|
57
|
-
catch {
|
|
58
|
-
// npm not installed or no global claudeup
|
|
59
|
-
}
|
|
60
|
-
// Warn about duplicate installations
|
|
61
|
-
if (installations.length > 1) {
|
|
62
|
-
const activePath = execSync("which claudeup", {
|
|
63
|
-
encoding: "utf-8",
|
|
64
|
-
timeout: 5000,
|
|
65
|
-
}).trim();
|
|
66
|
-
console.log(`⚠ claudeup is installed via multiple package managers:\n`);
|
|
67
|
-
for (const inst of installations) {
|
|
68
|
-
const tag = inst.path === activePath ? " (active)" : " (shadowed)";
|
|
69
|
-
console.log(` ${inst.manager}: ${inst.path}${tag}`);
|
|
70
|
-
}
|
|
71
|
-
console.log(`\nTo fix, keep one and remove the other:`);
|
|
72
|
-
for (const inst of installations) {
|
|
73
|
-
console.log(` ${inst.manager} uninstall -g claudeup`);
|
|
74
|
-
}
|
|
75
|
-
console.log();
|
|
76
|
-
}
|
|
77
|
-
// Determine which package manager to use for the update
|
|
78
|
-
let usesBun = false;
|
|
79
|
-
try {
|
|
80
|
-
const claudeupPath = execSync("which claudeup", {
|
|
81
|
-
encoding: "utf-8",
|
|
82
|
-
}).trim();
|
|
83
|
-
usesBun =
|
|
84
|
-
claudeupPath.includes(".bun") || claudeupPath.includes("bun/bin");
|
|
85
|
-
}
|
|
86
|
-
catch {
|
|
87
|
-
// If which fails, default to npm
|
|
88
|
-
}
|
|
89
|
-
const pkgManager = usesBun ? "bun" : "npm";
|
|
90
|
-
console.log(`Updating claudeup using ${pkgManager}...`);
|
|
91
|
-
const installArgs = ["install", "-g", "claudeup@latest"];
|
|
92
|
-
const proc = spawn(pkgManager, installArgs, {
|
|
93
|
-
stdio: "inherit",
|
|
94
|
-
shell: false, // Avoid shell for security (fixes DEP0190 warning)
|
|
95
|
-
});
|
|
96
|
-
proc.on("exit", (code) => process.exit(code || 0));
|
|
97
|
-
return;
|
|
98
|
-
}
|
|
99
|
-
// Handle --version flag - show version and check for updates
|
|
100
|
-
if (args.includes("--version") || args.includes("-v")) {
|
|
101
|
-
console.log(`claudeup v${VERSION}`);
|
|
102
|
-
const result = await checkForUpdates();
|
|
103
|
-
if (result.updateAvailable) {
|
|
104
|
-
console.log(`\nUpdate available: v${result.latestVersion}`);
|
|
105
|
-
console.log("Run: claudeup update");
|
|
106
|
-
}
|
|
107
|
-
process.exit(0);
|
|
108
|
-
}
|
|
109
|
-
// Handle --help flag
|
|
110
|
-
if (args.includes("--help") || args.includes("-h")) {
|
|
111
|
-
console.log(`claudeup v${VERSION}
|
|
112
|
-
|
|
113
|
-
TUI tool for managing Claude Code plugins, MCPs, and configuration.
|
|
114
|
-
|
|
115
|
-
Usage: claudeup [options]
|
|
116
|
-
claudeup claude [args...] Run claude with auto-update prerunner
|
|
117
|
-
claudeup update Update claudeup to latest version
|
|
118
|
-
|
|
119
|
-
Options:
|
|
120
|
-
-v, --version Show version and check for updates
|
|
121
|
-
-h, --help Show this help message
|
|
122
|
-
--no-refresh Skip auto-refresh of marketplaces on startup
|
|
123
|
-
|
|
124
|
-
Commands:
|
|
125
|
-
claude [args...] Check for plugin updates (1h cache), then run claude
|
|
126
|
-
-f, --force Force update check (bypass 1h cache)
|
|
127
|
-
update Update claudeup itself to latest version
|
|
128
|
-
|
|
129
|
-
Navigation:
|
|
130
|
-
[1] Plugins Manage plugin marketplaces and installed plugins
|
|
131
|
-
[2] MCP Setup and manage MCP servers
|
|
132
|
-
[3] Status Configure status line display
|
|
133
|
-
[4] Env Environment variables for MCP servers
|
|
134
|
-
[5] Tools Install and update AI coding CLI tools
|
|
135
|
-
|
|
136
|
-
Keys:
|
|
137
|
-
↑/↓ or j/k Navigate
|
|
138
|
-
Enter Select / Toggle
|
|
139
|
-
g Toggle global/project scope (in Plugins)
|
|
140
|
-
r Refresh current screen
|
|
141
|
-
? Show help
|
|
142
|
-
q / Escape Back / Quit
|
|
143
|
-
`);
|
|
144
|
-
process.exit(0);
|
|
145
|
-
}
|
|
146
|
-
// Create OpenTUI renderer (handles alternate screen buffer automatically)
|
|
147
|
-
const renderer = await createCliRenderer();
|
|
148
|
-
const root = createRoot(renderer);
|
|
149
|
-
// Cleanup function to restore terminal
|
|
150
|
-
const cleanup = () => {
|
|
151
|
-
root.unmount();
|
|
152
|
-
renderer.destroy(); // CRITICAL: Never use process.exit() directly
|
|
153
|
-
};
|
|
154
|
-
// Handle cleanup on exit signals
|
|
155
|
-
const handleExit = () => {
|
|
156
|
-
cleanup();
|
|
157
|
-
// Exit after cleanup completes
|
|
158
|
-
process.exit(0);
|
|
159
|
-
};
|
|
160
|
-
process.on("SIGINT", handleExit);
|
|
161
|
-
process.on("SIGTERM", handleExit);
|
|
162
|
-
// Render the OpenTUI app with exit handler
|
|
163
|
-
root.render(_jsx(App, { onExit: handleExit }));
|
|
164
|
-
// Wait indefinitely (app runs until user exits)
|
|
165
|
-
await new Promise(() => { });
|
|
166
|
-
}
|
|
167
|
-
main().catch((error) => {
|
|
168
|
-
console.error("Error starting claudeup:", error);
|
|
169
|
-
process.exit(1);
|
|
170
|
-
});
|