mirror of
https://github.com/Nikolay-Shirokov/cc-1c-skills.git
synced 2026-09-04 01:00:52 +03:00
Replace literal `.claude/skills/<owner>/...` paths in SKILL.md with the
`${CLAUDE_SKILL_DIR}` variable that Claude Code substitutes at invocation
time. Same-skill references become `${CLAUDE_SKILL_DIR}/<rest>`,
cross-skill references (erf-* → epf-*) become
`${CLAUDE_SKILL_DIR}/../<other>/<rest>`. All paths now wrapped in double
quotes to handle install locations with spaces.
This unblocks plugin-mode installation: literal `.claude/skills/...`
paths fail when the skill is loaded from `~/.claude/plugins/cache/...`
or from a personal `~/.claude/skills/` install. Drop-in mode continues
to work because Claude Code resolves the variable in all install scopes.
Verified via pilot:
- Project drop-in (cc-1c-skills repo)
- Personal `~/.claude/skills/cf-info/`
- Plugin via `/plugin marketplace add <local-path>`
Scope: 61 SKILL.md, 125 path replacements (8 cross-skill).
Scripts unchanged — they already use \$PSScriptRoot and ../<sibling>
patterns that resolve correctly under the bundled cache layout.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
50 lines
1.9 KiB
Markdown
50 lines
1.9 KiB
Markdown
---
|
||
name: cf-init
|
||
description: Создать пустую конфигурацию 1С (scaffold XML-исходников). Используй когда нужно начать новую конфигурацию с нуля
|
||
argument-hint: <Name> [-Synonym <name>] [-OutputDir src]
|
||
allowed-tools:
|
||
- Bash
|
||
- Read
|
||
- Glob
|
||
---
|
||
|
||
# /cf-init — Создание пустой конфигурации 1С
|
||
|
||
Создаёт scaffold исходников пустой конфигурации 1С: `Configuration.xml`, `Languages/Русский.xml`.
|
||
|
||
## Параметры и команда
|
||
|
||
| Параметр | Описание |
|
||
|----------|----------|
|
||
| `Name` | Имя конфигурации (обязат.) |
|
||
| `Synonym` | Синоним (= Name если не указан) |
|
||
| `OutputDir` | Каталог для создания (default: `src`) |
|
||
| `Version` | Версия конфигурации |
|
||
| `Vendor` | Поставщик |
|
||
| `CompatibilityMode` | Режим совместимости (default: `Version8_3_24`) |
|
||
|
||
```powershell
|
||
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/cf-init.ps1" -Name "МояКонфигурация"
|
||
```
|
||
|
||
## Примеры
|
||
|
||
```powershell
|
||
# Базовая конфигурация
|
||
... -Name МояКонфигурация -Synonym "Моя конфигурация" -OutputDir test-tmp/cf
|
||
|
||
# С версией и поставщиком
|
||
... -Name TestCfg -Synonym "Тестовая" -Version "1.0.0.1" -Vendor "Фирма 1С" -OutputDir test-tmp/cf2
|
||
|
||
# Другой режим совместимости
|
||
... -Name TestCfg -CompatibilityMode Version8_3_27 -OutputDir test-tmp/cf3
|
||
```
|
||
|
||
## Верификация
|
||
|
||
```
|
||
/cf-init TestConfig -OutputDir test-tmp/cf
|
||
/cf-info test-tmp/cf — проверить созданное
|
||
/cf-validate test-tmp/cf — валидировать
|
||
```
|