Skip to content
Back to search

skill-porter

Universal tool to convert Claude Code skills to Gemini CLI extensions and vice versa

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/jduncan-rva--skill-porter/badge.svg)](/listings/jduncan-rva--skill-porter)

HTML

<a href="/listings/jduncan-rva--skill-porter"><img src="/api/listings/jduncan-rva--skill-porter/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

npm install -g skill-porter

Or use directly with npx:

npx skill-porter convert ./my-skill --to gemini

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 40 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. {
  2. "name": "skill-porter-marketplace",
  3. "owner": {
  4. "name": "jduncan-rva",
  5. "email": "jamie.e.duncan@gmail.com"
  6. },
  7. "metadata": {
  8. "description": "Universal tool to convert Claude Code skills to Gemini CLI extensions and vice versa",
  9. "version": "0.1.0"
  10. },
  11. "plugins": [
  12. {
  13. "name": "skill-porter",
  14. "description": "Converts Claude Code skills to Gemini CLI extensions and vice versa. Use when the user wants to make a skill cross-platform compatible, port a skill between platforms, or create a universal extension that works on both Claude Code and Gemini CLI.",
  15. "source": ".",
  16. "strict": false,
  17. "author": "jduncan-rva",
  18. "homepage": "https://github.com/jduncan-rva/skill-porter",
  19. "repository": {
  20. "type": "git",
  21. "url": "https://github.com/jduncan-rva/skill-porter"
  22. },
  23. "license": "MIT",
  24. "keywords": [
  25. "claude-code",
  26. "gemini-cli",
  27. "converter",
  28. "cross-platform",
  29. "mcp",
  30. "skill",
  31. "extension"
  32. ],
  33. "category": "development",
  34. "tags": ["tools", "conversion", "platform"],
  35. "skills": [
  36. "."
  37. ]
  38. }
  39. ]
  40. }
README.md · README · 312 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Skill Porter
  2. Universal tool to convert Claude Code skills to Gemini CLI extensions and vice versa.
  3. ## Overview
  4. Skill Porter automates the conversion between Claude Code skills and Gemini CLI extensions, enabling developers to write once and deploy to both platforms with minimal effort.
  5. ### Key Features
  6. - **Bidirectional Conversion**: Claude → Gemini and Gemini → Claude
  7. - **Smart Analysis**: Automatically detects source platform and structure
  8. - **Metadata Transformation**: YAML frontmatter ↔ JSON manifest conversion
  9. - **MCP Integration**: Preserves Model Context Protocol server configurations
  10. - **Configuration Mapping**: Converts between environment variables and settings schemas
  11. - **Tool Restriction Conversion**: Transforms allowed-tools (allowlist) ↔ excludeTools (denylist)
  12. - **Validation**: Ensures output meets platform requirements
  13. - **Optional Features**: PR generation, fork setup, migration tools
  14. ## Installation
  15. ```bash
  16. npm install -g skill-porter
  17. ```
  18. Or use directly with npx:
  19. ```bash
  20. npx skill-porter convert ./my-skill --to gemini
  21. ```
  22. ## Quick Start
  23. ### Convert Claude Skill to Gemini Extension
  24. ```bash
  25. skill-porter convert ./my-claude-skill --to gemini --output ./my-gemini-extension
  26. ```
  27. ### Convert Gemini Extension to Claude Skill
  28. ```bash
  29. skill-porter convert ./my-gemini-extension --to claude --output ./my-claude-skill
  30. ```
  31. ### Validate Conversion
  32. ```bash
  33. skill-porter validate ./my-converted-skill
  34. ```
  35. ## Usage
  36. ### As a CLI Tool
  37. ```bash
  38. # Basic conversion
  39. skill-porter convert <source-path> --to <claude|gemini>
  40. # With output directory
  41. skill-porter convert ./source --to gemini --output ./destination
  42. # Analyze without converting
  43. skill-porter analyze ./skill-or-extension
  44. # Validate existing skill/extension
  45. skill-porter validate ./path
  46. # Make universal (works on both platforms)
  47. skill-porter universal ./my-skill
  48. # Create PR to add dual-platform support
  49. skill-porter create-pr ./my-skill --to gemini
  50. # Fork with dual-platform setup
  51. skill-porter fork ./my-skill --location ~/my-forks/skill-name
  52. ```
  53. ### As a Universal Skill/Extension
  54. skill-porter itself works on both platforms!
  55. **Claude Code:**
  56. ```bash
  57. # Install as skill
  58. git clone https://github.com/jduncan-rva/skill-porter ~/.claude/skills/skill-porter
  59. cd ~/.claude/skills/skill-porter
  60. npm install
  61. ```
  62. Then in Claude Code:
  63. ```
  64. "Convert my skill at ./my-skill to Gemini extension"
  65. "Make this Claude skill compatible with Gemini CLI"
  66. ```
  67. **Gemini CLI:**
  68. ```bash
  69. gemini extensions install https://github.com/jduncan-rva/skill-porter
  70. ```
  71. Then in Gemini:
  72. ```
  73. "Port this skill to work with Claude Code"
  74. "Create a universal version of this extension"
  75. ```
  76. ## Architecture
  77. Skill Porter leverages the fact that both platforms use the Model Context Protocol (MCP), achieving ~85% code reuse:
  78. ```
  79. Shared Components (85%):
  80. ├── MCP Server (100% reusable)
  81. ├── Documentation (85% reusable)
  82. ├── Scripts & Dependencies (100% reusable)
  83. Platform-Specific (15%):
  84. ├── Claude: SKILL.md + .claude-plugin/marketplace.json
  85. └── Gemini: GEMINI.md + gemini-extension.json
  86. ```
  87. ### Conversion Process
  88. 1. **Detect**: Analyze source to determine platform
  89. 2. **Extract**: Parse metadata, MCP config, documentation
  90. 3. **Transform**: Convert between platform formats
  91. 4. **Generate**: Create target platform files
  92. 5. **Validate**: Ensure output meets requirements
  93. ## Platform Mapping
  94. | Claude Code | Gemini CLI | Transformation |
  95. |-------------|------------|----------------|
  96. | `SKILL.md` frontmatter | `gemini-extension.json` | YAML → JSON |
  97. | `allowed-tools` (whitelist) | `excludeTools` (blacklist) | Logic inversion |
  98. | `.claude-plugin/marketplace.json` | `gemini-extension.json` | JSON merge |
  99. | Environment variables | `settings[]` schema | Inference |
  100. | `SKILL.md` content | `GEMINI.md` | Content adaptation |
  101. ## Examples
  102. See the `examples/` directory for complete working examples with before/after comparisons.
  103. ### Example 1: Code Formatter (Claude → Gemini)
  104. **Before** (Claude skill):
  105. - `SKILL.md` with YAML frontmatter
  106. - Allowed tools: Read, Write, Bash
  107. - MCP server with environment variables
  108. **After** (Gemini extension):
  109. ```bash
  110. skill-porter convert examples/simple-claude-skill --to gemini
  111. ```
  112. - `gemini-extension.json` with manifest
  113. - Excluded tools: All except Read, Write, Bash
  114. - Settings schema inferred from env vars
  115. - MCP paths use `${extensionPath}`
  116. ### Example 2: API Connector (Gemini → Claude)
  117. **Before** (Gemini extension):
  118. - `gemini-extension.json` with settings
  119. - Excluded tools: Bash, Edit, Write
  120. - Secret settings for API keys
  121. **After** (Claude skill):
  122. ```bash
  123. skill-porter convert examples/api-connector-gemini --to claude
  124. ```
  125. - `SKILL.md` with YAML frontmatter
  126. - Allowed tools: All except Bash, Edit, Write
  127. - Environment variable documentation generated
  128. - `.claude-plugin/marketplace.json` created
  129. ### Example 3: Universal Conversion
  130. **skill-porter itself** is universal - it converted itself!
  131. ```bash
  132. cd skill-porter
  133. skill-porter analyze .
  134. # Result: Platform: universal (high confidence)
  135. ```
  136. See `examples/README.md` for detailed before/after comparisons and conversion explanations.
  137. ## Optional Features
  138. ### Generate Pull Request
  139. Automatically create a PR to add dual-platform support to a repository:
  140. ```bash
  141. # Convert and create PR in one step
  142. skill-porter create-pr ./my-skill --to gemini
  143. # Options
  144. skill-porter create-pr ./my-skill \
  145. --to gemini \
  146. --base main \
  147. --remote origin \
  148. --draft # Create as draft PR
  149. ```
  150. **What it does:**
  151. 1. Converts the skill/extension to target platform
  152. 2. Creates a new branch (`skill-porter/add-dual-platform-support`)
  153. 3. Commits changes with detailed commit message
  154. 4. Pushes to remote
  155. 5. Creates PR with comprehensive description
  156. **Requirements:**
  157. - GitHub CLI (`gh`) installed and authenticated
  158. - Git repository with remote configured
  159. **PR includes:**
  160. - ✅ Complete description of changes
  161. - ✅ Benefits explanation
  162. - ✅ Testing checklist
  163. - ✅ Installation instructions for both platforms
  164. - ✅ Link to skill-porter documentation
  165. ### Fork and Setup
  166. Create a fork with dual-platform configuration ready for development:
  167. ```bash
  168. skill-porter fork ./my-skill --location ~/my-forks/skill-name
  169. ```
  170. **What it does:**
  171. 1. Creates fork directory at specified location
  172. 2. Copies or clones the repository
  173. 3. Ensures both Claude and Gemini configurations exist
  174. 4. Sets up symlinks for Claude Code (if applicable)
  175. 5. Provides installation instructions for Gemini CLI
  176. **Use cases:**
  177. - Maintain separate development fork
  178. - Test on both platforms simultaneously
  179. - Contribute dual-platform support to external repos
  180. ## Development
  181. ```bash
  182. # Clone repository
  183. git clone https://github.com/jduncan-rva/skill-porter
  184. cd skill-porter
  185. # Install dependencies
  186. npm install
  187. # Run in development mode
  188. npm run dev
  189. # Run tests
  190. npm test
  191. ```
  192. ## Contributing
  193. Contributions welcome! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
  194. ## Project Structure
  195. ```
  196. skill-porter/
  197. ├── src/
  198. │ ├── index.js # Main entry point
  199. │ ├── cli.js # CLI interface
  200. │ ├── analyzers/
  201. │ │ ├── detector.js # Platform detection
  202. │ │ └── validator.js # Output validation
  203. │ ├── converters/
  204. │ │ ├── claude-to-gemini.js
  205. │ │ ├── gemini-to-claude.js
  206. │ │ └── shared.js # Shared conversion logic
  207. │ ├── templates/
  208. │ │ ├── skill.template.md
  209. │ │ ├── gemini.template.md
  210. │ │ └── manifests.js # Manifest templates
  211. │ └── utils/
  212. │ ├── file-utils.js
  213. │ ├── metadata-parser.js
  214. │ └── mcp-transformer.js
  215. ├── tests/
  216. ├── examples/
  217. ├── SKILL.md # Claude Code skill interface
  218. ├── package.json
  219. └── README.md
  220. ```
  221. ## License
  222. MIT
  223. ## Acknowledgments
  224. - Built on the [Model Context Protocol](https://modelcontextprotocol.io)
  225. - Inspired by the universal extension pattern demonstrated in [database-query-helper](https://github.com/jduncan-rva/database-query-helper)
  226. - Supports [Claude Code](https://code.claude.com) and [Gemini CLI](https://geminicli.com)
  227. ## Support
  228. - **Issues**: https://github.com/jduncan-rva/skill-porter/issues
  229. - **Discussions**: https://github.com/jduncan-rva/skill-porter/discussions
  230. ---
  231. Made with ❤️ for the Claude Code and Gemini CLI communities

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.