New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

claude-code-forge

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

claude-code-forge

CLI tool to initialize Claude Code workspace with templates

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

claude-code-forge

CLI tool to initialize Claude Code workspace with templates.

Installation

npm install -g claude-code-forge

Or use directly with npx:

npx claude-code-forge

Usage

# Basic usage - interactive mode
npx claude-code-forge

# Specify target directory
npx claude-code-forge ./my-project

# With explicit repo
npx claude-code-forge --repo github.com/myorg/template

# Force SSH auth
npx claude-code-forge --ssh

# Use token auth
npx claude-code-forge --token ghp_xxxx

# Preview changes without making them
npx claude-code-forge --dry-run

# Overwrite without prompts
npx claude-code-forge --force

# Skip specific folders
npx claude-code-forge --skip-docs --skip-plans

Environment Variables

CLAUDE_FORGE_REPO=github.com/myorg/template
CLAUDE_FORGE_TOKEN=ghp_xxxx

CLI Options

OptionDescription
[target-dir]Target directory (default: .)
--repo <url>Template repository URL
--sshUse SSH authentication
--token <pat>Use GitHub Personal Access Token
--forceOverwrite existing files without prompts
--dry-runPreview changes only
--skip-docsSkip docs/ folder
--skip-plansSkip plans/ folder
-h, --helpDisplay help
-V, --versionDisplay version

Configuration

The tool saves configuration to ~/.claudeforgerc:

{
  "repo": "github.com/myorg/template",
  "auth": "ssh"
}

Configuration Priority

Repository URL:

  • --repo flag
  • CLAUDE_FORGE_REPO env
  • ~/.claudeforgerc
  • Interactive prompt

Authentication:

  • --ssh flag
  • --token flag
  • CLAUDE_FORGE_TOKEN env
  • Auto-detect SSH key
  • ~/.claudeforgerc
  • Interactive prompt

What Gets Copied

  • .claude/ - Workflows, skills, commands, agents
  • docs/ - Project documentation
  • plans/ - Implementation plans
  • CLAUDE.md - Claude Code instructions

Conflict Handling

When existing files are detected:

  • Overwrite all - Replace existing files
  • Merge - Keep existing, add only new files
  • Skip - Don't copy conflicting files
  • Cancel - Abort operation

Use --force to overwrite without prompts.

Troubleshooting

SSH Authentication Failed

# Check if SSH key exists
ls ~/.ssh/id_*

# Test GitHub SSH access
ssh -T git@github.com

Token Authentication Failed

Ensure your PAT has repo scope for private repositories.

Network Error

Check your internet connection and try again.

Development

# Clone
git clone https://github.com/nicholashopee/claude-code-forge
cd claude-code-forge

# Install dependencies
npm install

# Link for local testing
npm link

# Test
claude-code-forge --help

License

MIT

Keywords

claude

FAQs

Package last updated on 22 Dec 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts