mirror of
https://github.com/antonbabenko/terraform-skill.git
synced 2026-09-18 20:07:05 +08:00
chore: decommission self-published marketplace
terraform-skill distributed only via antonbabenko/agent-plugins. Deleted .claude-plugin/marketplace.json; release pipeline uses skip-version-file (SKILL.md frontmatter single mirror, git tags canonical). Sequenced after agent-plugins#4.
This commit is contained in:
@@ -1,34 +0,0 @@
|
||||
{
|
||||
"name": "antonbabenko",
|
||||
"owner": {
|
||||
"name": "Anton Babenko"
|
||||
},
|
||||
"version": "1.9.0",
|
||||
"metadata": {
|
||||
"description": "Use when writing, reviewing, or debugging Terraform/OpenTofu modules, tests, CI, scans, or state ops - diagnoses failure mode (identity churn, secrets, blast radius, CI drift, state corruption) with version-aware guards.",
|
||||
"repository": "https://github.com/antonbabenko/terraform-skill",
|
||||
"license": "Apache-2.0"
|
||||
},
|
||||
"plugins": [
|
||||
{
|
||||
"name": "terraform-skill",
|
||||
"description": "Use when writing, reviewing, or debugging Terraform/OpenTofu modules, tests, CI, scans, or state ops - diagnoses failure mode (identity churn, secrets, blast radius, CI drift, state corruption) with version-aware guards.",
|
||||
"source": "./",
|
||||
"category": "development",
|
||||
"keywords": [
|
||||
"terraform",
|
||||
"opentofu",
|
||||
"iac",
|
||||
"infrastructure-as-code",
|
||||
"state-management",
|
||||
"testing",
|
||||
"ci-cd",
|
||||
"security-scanning",
|
||||
"modules",
|
||||
"lsp",
|
||||
"terraform-ls"
|
||||
],
|
||||
"version": "1.9.0"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -42,10 +42,8 @@ jobs:
|
||||
preset: 'angular'
|
||||
tag-prefix: 'v'
|
||||
output-file: 'CHANGELOG.md'
|
||||
version-file: './.claude-plugin/marketplace.json'
|
||||
version-path: 'version'
|
||||
skip-on-empty: 'false'
|
||||
skip-version-file: 'false'
|
||||
skip-version-file: 'true'
|
||||
skip-commit: 'false'
|
||||
|
||||
# 2b. Sync plugin version, SKILL.md version, and git ref
|
||||
@@ -93,38 +91,10 @@ jobs:
|
||||
try:
|
||||
version = os.environ['VERSION']
|
||||
|
||||
# 1. Update marketplace.json
|
||||
with open('.claude-plugin/marketplace.json', 'r') as f:
|
||||
data = json.load(f)
|
||||
|
||||
# Validate structure
|
||||
if 'plugins' not in data or len(data['plugins']) == 0:
|
||||
raise ValueError("No plugins found in marketplace.json")
|
||||
|
||||
# Sync marketplace.json versions
|
||||
data['plugins'][0]['version'] = version
|
||||
|
||||
# Validate marketplace.json synced state
|
||||
if data['version'] != version:
|
||||
raise ValueError(f"Marketplace version {data['version']} != {version}")
|
||||
|
||||
with open('.claude-plugin/marketplace.json', 'w') as f:
|
||||
json.dump(data, f, indent=2)
|
||||
f.write('\n')
|
||||
|
||||
print(f"✅ Synced marketplace.json plugin version to {version}")
|
||||
|
||||
# 2. Update SKILL.md
|
||||
# SKILL.md frontmatter is the single version source.
|
||||
skill_path = update_skill_version(version)
|
||||
print(f"✅ Synced {skill_path} metadata.version to {version}")
|
||||
|
||||
# 3. Final validation - all three versions match
|
||||
print(f"\n📋 Version Sync Summary:")
|
||||
print(f" - marketplace.json root: {data['version']}")
|
||||
print(f" - marketplace.json plugins[0]: {data['plugins'][0]['version']}")
|
||||
print(f" - SKILL.md metadata: {version}")
|
||||
print(f" ✅ All versions synchronized to {version}")
|
||||
|
||||
except Exception as e:
|
||||
print(f"❌ ERROR: Failed to sync versions: {e}")
|
||||
sys.exit(1)
|
||||
@@ -133,7 +103,7 @@ jobs:
|
||||
# Commit the sync
|
||||
git config user.name "github-actions[bot]"
|
||||
git config user.email "github-actions[bot]@users.noreply.github.com"
|
||||
git add .claude-plugin/marketplace.json skills/terraform-skill/SKILL.md
|
||||
git add skills/terraform-skill/SKILL.md
|
||||
git commit --amend --no-edit
|
||||
git push --force-with-lease
|
||||
|
||||
|
||||
@@ -100,54 +100,6 @@ jobs:
|
||||
echo "✅ Size OK"
|
||||
fi
|
||||
|
||||
- name: Validate marketplace.json
|
||||
run: |
|
||||
python3 << 'EOF'
|
||||
import json
|
||||
import sys
|
||||
import re
|
||||
|
||||
print("🔍 Validating marketplace.json...")
|
||||
|
||||
with open('.claude-plugin/marketplace.json', 'r') as f:
|
||||
marketplace = json.load(f)
|
||||
|
||||
# Validate marketplace-level fields
|
||||
required_marketplace = ['name', 'owner', 'version', 'plugins']
|
||||
missing = [f for f in required_marketplace if f not in marketplace]
|
||||
|
||||
if missing:
|
||||
print(f"❌ ERROR: Missing marketplace fields: {missing}")
|
||||
sys.exit(1)
|
||||
|
||||
# Validate owner structure
|
||||
if 'name' not in marketplace['owner']:
|
||||
print("❌ ERROR: owner must have 'name'")
|
||||
sys.exit(1)
|
||||
|
||||
# Validate version format
|
||||
version = marketplace['version']
|
||||
if not re.match(r'^\d+\.\d+\.\d+$', version):
|
||||
print(f"❌ ERROR: Invalid marketplace version: {version}")
|
||||
sys.exit(1)
|
||||
|
||||
# Validate plugins array
|
||||
if not isinstance(marketplace['plugins'], list) or len(marketplace['plugins']) == 0:
|
||||
print("❌ ERROR: 'plugins' must be a non-empty array")
|
||||
sys.exit(1)
|
||||
|
||||
# Validate each plugin
|
||||
for idx, plugin in enumerate(marketplace['plugins']):
|
||||
required_plugin = ['name', 'description', 'source']
|
||||
missing = [f for f in required_plugin if f not in plugin]
|
||||
|
||||
if missing:
|
||||
print(f"❌ ERROR: Plugin {idx} missing fields: {missing}")
|
||||
sys.exit(1)
|
||||
|
||||
print(f"✅ marketplace.json valid (v{version}, {len(marketplace['plugins'])} plugin(s))")
|
||||
EOF
|
||||
|
||||
- name: Check for Broken Links
|
||||
run: |
|
||||
echo "🔍 Checking internal links..."
|
||||
|
||||
@@ -14,7 +14,6 @@ A **Claude Code skill** - executable documentation that Claude loads to provide
|
||||
|
||||
```
|
||||
terraform-skill/
|
||||
├── .claude-plugin/marketplace.json # Plugin metadata (version synced automatically)
|
||||
├── skills/
|
||||
│ └── terraform-skill/ # Skill autodiscovered by Claude Code plugin system
|
||||
│ ├── SKILL.md # Core skill file (~299 lines)
|
||||
@@ -88,10 +87,9 @@ Releases are **fully automated** from conventional commits on `master`:
|
||||
|
||||
The release workflow automatically:
|
||||
- Bumps the version in `CHANGELOG.md`
|
||||
- Syncs versions across **three places** (must stay in sync):
|
||||
1. `.claude-plugin/marketplace.json` → `version` (root)
|
||||
2. `.claude-plugin/marketplace.json` → `plugins[0].version`
|
||||
3. `skills/terraform-skill/SKILL.md` YAML frontmatter → `metadata.version`
|
||||
- Syncs `skills/terraform-skill/SKILL.md` YAML frontmatter
|
||||
`metadata.version` (the single version source; the canonical version is the
|
||||
git tag managed by the release pipeline)
|
||||
|
||||
**Never manually edit version numbers** - the CI handles this.
|
||||
|
||||
|
||||
+1
-2
@@ -326,7 +326,7 @@ git commit -m "docs: improve testing strategy documentation"
|
||||
git commit -m "chore: update workflow dependencies"
|
||||
```
|
||||
|
||||
Commit type determines the version bump, the changelog group, and whether a release is cut on merge to master. The release workflow updates the version in marketplace.json (marketplace root and plugin entry) and in SKILL.md frontmatter.
|
||||
Commit type determines the version bump, the changelog group, and whether a release is cut on merge to master. The release workflow updates the version in SKILL.md frontmatter (the single version source) and tags the release.
|
||||
|
||||
## Submitting Changes
|
||||
|
||||
@@ -379,7 +379,6 @@ Releases are automated from conventional commits:
|
||||
2. Workflow analyzes commits since the last release
|
||||
3. Workflow calculates the version bump (major/minor/patch)
|
||||
4. Workflow updates:
|
||||
- `.claude-plugin/marketplace.json` (marketplace version, plugin version, git ref)
|
||||
- `skills/terraform-skill/SKILL.md` frontmatter (`metadata.version`)
|
||||
- `CHANGELOG.md` (generated from commits)
|
||||
5. Workflow creates the git tag and GitHub Release
|
||||
|
||||
Reference in New Issue
Block a user