소스 정보
- 저장소
- fabioc-aloha/alex-cognitive-architecture
- 최근 소스 활동
- 2026년 4월 23일 03:10
- 감지된 SKILL.md 언어
- 영어
- 스타
- 0
- 포크
- 1
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/fabioc-aloha/alex-cognitive-architecture --skill vscode-configuration-validation명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SOC 직업 분류 기준
SKILL.md 표시 중
| name | vscode-configuration-validation |
| description | Validate VS Code extension manifest against runtime code usage |
| tier | standard |
| applyTo | **/package.json,**/.vscode/**,**/tsconfig* |
| currency | 2026-04-22T00:00:00.000Z |
Domain: VS Code extension development, configuration management, quality assurance
Complexity: Intermediate
Prerequisites: Understanding of VS Code extension manifest (package.json), TypeScript
VS Code extensions fail at runtime when:
package.jsonThese misconfigurations don't cause compile-time errors and only surface when users interact with specific features.
Systematic validation of VS Code extension manifest against runtime code usage.
Check: All workspace.getConfiguration().update() calls reference registered properties.
// ❌ WRONG - config key not registered
await vscode.workspace.getConfiguration('alex.skillRecommendations')
.update('code-review.accepted', count + 1, ConfigurationTarget.Global);
// ✅ RIGHT - key registered in package.json or wrapped in try-catch
try {
await vscode.workspace.getConfiguration('alex.skillRecommendations')
.update('code-review.accepted', count + 1, ConfigurationTarget.Global);
} catch (error) {
console.log(`Skip tracking: ${error}`);
}
Audit Pattern:
# Find all config.update() calls
grep -r "getConfiguration.*\.update\(" src/
# Cross-reference with package.json properties section
# Each update() key must exist in "configuration.properties"
Check: All commands.registerCommand() calls match declared commands in manifest.
// Code registration
vscode.commands.registerCommand('alex.validateHeir', async () => {...});
// Must have package.json declaration
{
"contributes": {
"commands": [{
"command": "alex.validateHeir",
"title": "Validate as Heir Project"
}]
}
}
Audit Pattern:
# Find all command registrations
grep -r "registerCommand\(['\"]alex\." src/
# Extract command names and verify each exists in package.json
Check: All getConfiguration().get() calls match registered properties.
// This config read should have a registered property
const enabled = vscode.workspace.getConfiguration('alex.voice').get('enabled', false);
// Check package.json has "alex.voice.enabled"
Warning Pattern: Configuration reads with no defaults are risky:
// ⚠️ No fallback - will be undefined if not registered
const value = config.get('someKey');
// ✅ Better - always provide default
const value = config.get('someKey', defaultValue);
For Dynamic Configuration Keys (skill recommendations, user preferences):
Option A: Register schema with dynamic pattern (complex) Option B: Graceful try-catch (simple, recommended)
// Pattern: Non-critical dynamic config
async function trackUserPreference(key: string, value: any) {
try {
await vscode.workspace.getConfiguration('alex.dynamic')
.update(key, value, ConfigurationTarget.Global);
} catch (error) {
// Log but don't fail - tracking is optional
console.log(`[Alex] Skipping preference tracking: ${error}`);
}
}
For Critical Configuration:
// Pattern: Essential config must be registered
await vscode.workspace.getConfiguration('alex.globalKnowledge')
.update('remoteRepo', repo, ConfigurationTarget.Global);
// No try-catch - failure should bubble up
getConfiguration().update() callspackage.json properties OR has try-catchregisterCommand() callscontributes.commandsPseudocode: validate-manifest
1. Search src/**/*.ts for getConfiguration('section').update('key') calls
2. Load contributes.configuration.properties from package.json
3. For each config update found in source code:
If the full key (section.key) is NOT in package.json properties:
Flag as unregistered config write (potential runtime error)
4. Report all mismatches
$issues += "⚠️ $fullKey - not registered (verify try-catch exists)"
} }
if ($issues.Count -gt 0) { Write-Host "Configuration validation issues:" -ForegroundColor Yellow $issues | ForEach-Object { Write-Host $_ } exit 1 }
## Common Pitfalls
1. **Dynamic Configuration Keys**: User preferences, tracking counters
- **Solution**: Either register dynamic schema or use try-catch pattern
2. **Namespaced Configuration**: `alex.skill.subkey.value`
- **Solution**: Register full dotted path: `"alex.skill.subkey.value": {...}`
3. **Multi-Target Updates**: Workspace vs Global vs WorkspaceFolder
- **Solution**: Test configuration across all scopes
4. **Configuration Migration**: Deprecated settings
- **Solution**: Use `deprecationMessage` in property definition
## Real-World Example: Skill Recommendations
**Problem**: Tracking skill usage without bloating package.json with hundreds of dynamic keys.
**Solution**: Graceful degradation pattern
```typescript
async function trackRecommendation(skillId: string, accepted: boolean) {
try {
const context = 'alex.skillRecommendations';
const key = `${skillId}.${accepted ? 'accepted' : 'dismissed'}`;
const current = vscode.workspace.getConfiguration(context).get<number>(key, 0);
await vscode.workspace.getConfiguration(context).update(
key,
current + 1,
vscode.ConfigurationTarget.Global
);
} catch (error) {
// Feature degrades gracefully - recommendations still work
console.log(`[Alex] Skipping recommendation tracking: ${error}`);
}
}
Why This Works:
Add to .github/instructions/extension-audit-methodology.instructions.md:
### Configuration Validation
Before each release:
1. Run `node scripts/release-preflight.cjs`
2. Review any warnings for try-catch coverage
3. Test configuration updates in clean VS Code instance
4. Verify error messages are user-friendly
Sources of Truth:
alex.skillRecommendations.* keys not in package.jsonsrc/chat/skillRecommendations.ts