universal-dev-standards 3.2.2-beta.2 → 3.2.2

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/README.md CHANGED
@@ -119,6 +119,39 @@ uds update --yes
119
119
  **Options | 選項:**
120
120
  - `-y, --yes` - Skip confirmation prompts | 跳過確認提示
121
121
 
122
+ ### `uds skills`
123
+
124
+ List installed Claude Code skills. | 列出已安裝的 Claude Code Skills。
125
+
126
+ ```bash
127
+ uds skills
128
+ ```
129
+
130
+ **Output includes | 輸出內容:**
131
+ - Installation location (Plugin Marketplace, User Level, Project Level) | 安裝位置
132
+ - Installed version | 已安裝版本
133
+ - List of installed skills | 已安裝的 Skills 清單
134
+ - Migration recommendations for deprecated installations | 棄用安裝的遷移建議
135
+
136
+ **Example Output | 範例輸出:**
137
+ ```
138
+ Universal Dev Standards - Installed Skills
139
+ ──────────────────────────────────────────────────
140
+
141
+ ✓ Plugin Marketplace (recommended)
142
+ Version: 3.2.2
143
+ Path: /Users/.../.claude/plugins/universal-dev-standards@...
144
+
145
+ Skills (14):
146
+ ✓ ai-collaboration-standards
147
+ ✓ changelog-guide
148
+ ✓ code-review-assistant
149
+ ...
150
+
151
+ ──────────────────────────────────────────────────
152
+ Total unique skills: 14 / 14
153
+ ```
154
+
122
155
  ## Adoption Levels | 採用等級
123
156
 
124
157
  | Level | Name | Description | 說明 |
@@ -273,6 +306,7 @@ Git 鉤子透過 Git Bash 運作,它包含在 Git for Windows 中。不需要
273
306
 
274
307
  | Version | Date | Changes |
275
308
  |---------|------|---------|
309
+ | 3.2.2 | 2026-01-06 | Added: `uds skills` command to list installed Claude Code skills; Deprecated: manual installation scripts |
276
310
  | 3.2.0 | 2026-01-02 | Added: Marketplace installation support; Fixed: wildcard paths, process hanging |
277
311
  | 3.0.0 | 2025-12-30 | Published to npm, enhanced init with AI tools selection |
278
312
  | 1.0.1 | 2025-12-24 | Added: Bilingual support (English + Chinese) |
package/bin/uds.js CHANGED
@@ -7,6 +7,7 @@ import { initCommand } from '../src/commands/init.js';
7
7
  import { checkCommand } from '../src/commands/check.js';
8
8
  import { updateCommand } from '../src/commands/update.js';
9
9
  import { configureCommand } from '../src/commands/configure.js';
10
+ import { skillsCommand } from '../src/commands/skills.js';
10
11
 
11
12
  const require = createRequire(import.meta.url);
12
13
  const pkg = require('../package.json');
@@ -57,4 +58,9 @@ program
57
58
  .option('-y, --yes', 'Skip confirmation prompts')
58
59
  .action(updateCommand);
59
60
 
61
+ program
62
+ .command('skills')
63
+ .description('List installed Claude Code skills')
64
+ .action(skillsCommand);
65
+
60
66
  program.parse();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "universal-dev-standards",
3
- "version": "3.2.2-beta.2",
3
+ "version": "3.2.2",
4
4
  "description": "CLI tool for adopting Universal Development Standards",
5
5
  "keywords": [
6
6
  "documentation",
@@ -0,0 +1,233 @@
1
+ import chalk from 'chalk';
2
+ import { existsSync, readdirSync, readFileSync } from 'fs';
3
+ import { join } from 'path';
4
+ import { homedir } from 'os';
5
+ import { getAllSkillNames } from '../utils/registry.js';
6
+
7
+ // Known skill directories (non-skill items to exclude)
8
+ const NON_SKILL_ITEMS = [
9
+ 'README.md',
10
+ 'CONTRIBUTING.template.md',
11
+ 'install.sh',
12
+ 'install.ps1',
13
+ 'universal-dev-standards',
14
+ '.manifest.json',
15
+ '.DS_Store'
16
+ ];
17
+
18
+ /**
19
+ * Get installed plugins info from Claude Code
20
+ * @returns {Object|null} Plugins info or null
21
+ */
22
+ function getInstalledPlugins() {
23
+ const pluginsPath = join(homedir(), '.claude', 'plugins', 'installed_plugins.json');
24
+
25
+ if (!existsSync(pluginsPath)) {
26
+ return null;
27
+ }
28
+
29
+ try {
30
+ return JSON.parse(readFileSync(pluginsPath, 'utf-8'));
31
+ } catch {
32
+ return null;
33
+ }
34
+ }
35
+
36
+ /**
37
+ * Find universal-dev-standards plugin in installed plugins
38
+ * @param {Object} pluginsInfo - Installed plugins info
39
+ * @returns {Object|null} Plugin info or null
40
+ */
41
+ function findUdsPlugin(pluginsInfo) {
42
+ if (!pluginsInfo?.plugins) {
43
+ return null;
44
+ }
45
+
46
+ // Look for universal-dev-standards plugin
47
+ for (const [key, installations] of Object.entries(pluginsInfo.plugins)) {
48
+ if (key.includes('universal-dev-standards')) {
49
+ // Return the first (usually only) installation
50
+ if (installations.length > 0) {
51
+ return {
52
+ key,
53
+ ...installations[0]
54
+ };
55
+ }
56
+ }
57
+ }
58
+
59
+ return null;
60
+ }
61
+
62
+ /**
63
+ * List skill directories in a path
64
+ * @param {string} dirPath - Directory path to scan
65
+ * @returns {string[]} Array of skill names
66
+ */
67
+ function listSkillsInDir(dirPath) {
68
+ if (!existsSync(dirPath)) {
69
+ return [];
70
+ }
71
+
72
+ try {
73
+ const items = readdirSync(dirPath, { withFileTypes: true });
74
+ return items
75
+ .filter(item => item.isDirectory() && !NON_SKILL_ITEMS.includes(item.name))
76
+ .map(item => item.name)
77
+ .sort();
78
+ } catch {
79
+ return [];
80
+ }
81
+ }
82
+
83
+ /**
84
+ * Skills command - list installed skills
85
+ */
86
+ export function skillsCommand() {
87
+ const projectPath = process.cwd();
88
+
89
+ console.log();
90
+ console.log(chalk.bold('Universal Dev Standards - Installed Skills'));
91
+ console.log(chalk.gray('─'.repeat(50)));
92
+ console.log();
93
+
94
+ // Get all known skills from registry
95
+ const knownSkills = getAllSkillNames();
96
+
97
+ // Check different installation locations
98
+ const installations = [];
99
+
100
+ // 1. Check Plugin Marketplace installation
101
+ const pluginsInfo = getInstalledPlugins();
102
+ const udsPlugin = findUdsPlugin(pluginsInfo);
103
+
104
+ if (udsPlugin && udsPlugin.installPath && existsSync(udsPlugin.installPath)) {
105
+ const skills = listSkillsInDir(udsPlugin.installPath);
106
+ if (skills.length > 0) {
107
+ installations.push({
108
+ location: 'Plugin Marketplace',
109
+ path: udsPlugin.installPath,
110
+ version: udsPlugin.version || 'unknown',
111
+ skills,
112
+ recommended: true
113
+ });
114
+ }
115
+ }
116
+
117
+ // 2. Check user-level installation (~/.claude/skills/)
118
+ const userSkillsDir = join(homedir(), '.claude', 'skills');
119
+ if (existsSync(userSkillsDir)) {
120
+ const skills = listSkillsInDir(userSkillsDir);
121
+ // Filter to only known UDS skills
122
+ const udsSkills = skills.filter(s => knownSkills.includes(s));
123
+ if (udsSkills.length > 0) {
124
+ // Check for manifest
125
+ const manifestPath = join(userSkillsDir, '.manifest.json');
126
+ let version = 'unknown';
127
+ if (existsSync(manifestPath)) {
128
+ try {
129
+ const manifest = JSON.parse(readFileSync(manifestPath, 'utf-8'));
130
+ version = manifest.version || 'unknown';
131
+ } catch {
132
+ // ignore
133
+ }
134
+ }
135
+
136
+ installations.push({
137
+ location: 'User Level (deprecated)',
138
+ path: userSkillsDir,
139
+ version,
140
+ skills: udsSkills,
141
+ deprecated: true
142
+ });
143
+ }
144
+ }
145
+
146
+ // 3. Check project-level installation (.claude/skills/)
147
+ const projectSkillsDir = join(projectPath, '.claude', 'skills');
148
+ if (existsSync(projectSkillsDir)) {
149
+ const skills = listSkillsInDir(projectSkillsDir);
150
+ // Filter to only known UDS skills
151
+ const udsSkills = skills.filter(s => knownSkills.includes(s));
152
+ if (udsSkills.length > 0) {
153
+ // Check for manifest
154
+ const manifestPath = join(projectSkillsDir, '.manifest.json');
155
+ let version = 'unknown';
156
+ if (existsSync(manifestPath)) {
157
+ try {
158
+ const manifest = JSON.parse(readFileSync(manifestPath, 'utf-8'));
159
+ version = manifest.version || 'unknown';
160
+ } catch {
161
+ // ignore
162
+ }
163
+ }
164
+
165
+ installations.push({
166
+ location: 'Project Level (deprecated)',
167
+ path: projectSkillsDir,
168
+ version,
169
+ skills: udsSkills,
170
+ deprecated: true
171
+ });
172
+ }
173
+ }
174
+
175
+ // Display results
176
+ if (installations.length === 0) {
177
+ console.log(chalk.yellow('No Universal Dev Standards skills installed.'));
178
+ console.log();
179
+ console.log(chalk.gray('Install via Plugin Marketplace:'));
180
+ console.log(chalk.cyan(' /plugin marketplace add AsiaOstrich/universal-dev-standards'));
181
+ console.log(chalk.cyan(' /plugin install universal-dev-standards@universal-dev-standards'));
182
+ console.log();
183
+ return;
184
+ }
185
+
186
+ // Show each installation
187
+ for (const install of installations) {
188
+ // Header
189
+ if (install.recommended) {
190
+ console.log(chalk.green(`✓ ${install.location}`) + chalk.gray(' (recommended)'));
191
+ } else if (install.deprecated) {
192
+ console.log(chalk.yellow(`⚠ ${install.location}`));
193
+ } else {
194
+ console.log(chalk.blue(`● ${install.location}`));
195
+ }
196
+
197
+ console.log(chalk.gray(` Version: ${install.version}`));
198
+ console.log(chalk.gray(` Path: ${install.path}`));
199
+ console.log();
200
+
201
+ // Skills list
202
+ console.log(chalk.gray(` Skills (${install.skills.length}):`));
203
+ for (const skill of install.skills) {
204
+ const icon = install.deprecated ? chalk.yellow('○') : chalk.green('✓');
205
+ console.log(` ${icon} ${skill}`);
206
+ }
207
+ console.log();
208
+
209
+ // Deprecation warning
210
+ if (install.deprecated) {
211
+ console.log(chalk.yellow(' ⚠ Manual installation is deprecated.'));
212
+ console.log(chalk.gray(' Migrate to Plugin Marketplace for automatic updates:'));
213
+ console.log(chalk.cyan(' /plugin marketplace add AsiaOstrich/universal-dev-standards'));
214
+ console.log(chalk.cyan(' /plugin install universal-dev-standards@universal-dev-standards'));
215
+ console.log();
216
+ }
217
+ }
218
+
219
+ // Summary
220
+ const totalSkills = new Set(installations.flatMap(i => i.skills)).size;
221
+ const hasMarketplace = installations.some(i => i.recommended);
222
+
223
+ console.log(chalk.gray('─'.repeat(50)));
224
+ console.log(chalk.gray(`Total unique skills: ${totalSkills} / ${knownSkills.length}`));
225
+
226
+ if (!hasMarketplace && installations.length > 0) {
227
+ console.log();
228
+ console.log(chalk.yellow('Recommendation: Migrate to Plugin Marketplace'));
229
+ console.log(chalk.gray(' Benefits: Automatic updates, better integration'));
230
+ }
231
+
232
+ console.log();
233
+ }
@@ -177,8 +177,33 @@ export async function updateCommand(options) {
177
177
  console.log(chalk.cyan('Skills update available:'));
178
178
  console.log(chalk.gray(` Current: ${manifest.skills.version || 'unknown'}`));
179
179
  console.log(chalk.gray(` Latest: ${skillsVersion}`));
180
- console.log(chalk.gray(' Run the following to update:'));
181
- console.log(chalk.gray(' cd path/to/universal-dev-skills && git pull && ./install.sh'));
180
+ console.log();
181
+
182
+ // Check installation location to provide appropriate update instructions
183
+ const location = manifest.skills.location || 'unknown';
184
+
185
+ if (location === 'marketplace') {
186
+ console.log(chalk.gray(' Update via Plugin Marketplace:'));
187
+ console.log(chalk.gray(' • Auto-update: Restart Claude Code (updates on startup)'));
188
+ console.log(chalk.gray(' • Manual: Run /plugin marketplace update anthropic-agent-skills'));
189
+ } else if (location === 'user') {
190
+ console.log(chalk.yellow(' ⚠️ Manual installation is deprecated'));
191
+ console.log(chalk.gray(' Recommended: Migrate to Plugin Marketplace'));
192
+ console.log(chalk.gray(' /plugin add https://github.com/anthropics/claude-code-plugins/blob/main/skills/universal-dev-standards.md'));
193
+ console.log(chalk.gray(' Or update manually:'));
194
+ console.log(chalk.gray(' cd ~/.claude/skills/universal-dev-standards && git pull'));
195
+ } else if (location === 'project') {
196
+ console.log(chalk.yellow(' ⚠️ Manual installation is deprecated'));
197
+ console.log(chalk.gray(' Recommended: Migrate to Plugin Marketplace'));
198
+ console.log(chalk.gray(' /plugin add https://github.com/anthropics/claude-code-plugins/blob/main/skills/universal-dev-standards.md'));
199
+ console.log(chalk.gray(' Or update manually:'));
200
+ console.log(chalk.gray(' cd .claude/skills/universal-dev-standards && git pull'));
201
+ } else {
202
+ // Legacy or unknown installation
203
+ console.log(chalk.yellow(' ⚠️ Manual installation is deprecated'));
204
+ console.log(chalk.gray(' Recommended: Migrate to Plugin Marketplace'));
205
+ console.log(chalk.gray(' /plugin add https://github.com/anthropics/claude-code-plugins/blob/main/skills/universal-dev-standards.md'));
206
+ }
182
207
  }
183
208
  }
184
209
 
package/src/index.js CHANGED
@@ -5,3 +5,4 @@ export { listCommand } from './commands/list.js';
5
5
  export { initCommand } from './commands/init.js';
6
6
  export { checkCommand } from './commands/check.js';
7
7
  export { updateCommand } from './commands/update.js';
8
+ export { skillsCommand } from './commands/skills.js';
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "version": "3.2.2",
4
- "lastUpdated": "2026-01-05",
4
+ "lastUpdated": "2026-01-06",
5
5
  "description": "Standards registry for universal-dev-standards with integrated skills and AI-optimized formats",
6
6
  "formats": {
7
7
  "ai": {