Repository navigation
feat: add Continue CLI (cn) installer and converter #3757
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,174 @@ | ||
| # ECC for the Continue CLI (`cn`) | ||
|
|
||
| This fork can install ECC's rules, skills, slash commands, agents, MCP servers and guardrails into the [Continue CLI](https://docs.continue.dev/cli/overview). Nothing in the upstream ECC content is edited. A converter (`scripts/install-continue.js`) translates each piece into the format `cn` actually loads and writes it under `~/.continue`. | ||
|
|
||
| Verified against `@continuedev/cli` 1.5.47, the latest release as of October 2026. | ||
|
|
||
| ## What you get | ||
|
|
||
| | ECC (Claude Code) | Continue CLI | How you use it | | ||
| |---|---|---| | ||
| | `rules/common` + language packs | `~/.continue/rules/ecc/*.md` (always applied) | Automatic in every session | | ||
| | `skills/<name>/SKILL.md` | `~/.continue/skills/<name>/` | The model loads them with the **Skills** tool; you can type `/skill-<name>` | | ||
| | `commands/*.md` (97) + `contexts/` (3) | `prompts:` in `config.yaml` | `/plan`, `/code-review`, `/build-fix`, `/ctx-dev` ... in the TUI | | ||
| | `agents/*.md` (71) | `~/.continue/ecc/agents/*.md` agent files | `ecc-agent code-reviewer "review my diff"` (= `cn --agent <file>`) | | ||
| | `agents/` (optional) | Subagent models (`roles: [subagent]`) | `cn --beta-subagent-tool`, then the model delegates | | ||
| | `mcp-configs/mcp-servers.json` | `mcpServers:` in `config.yaml` | Opt in per server with `--mcp` | | ||
| | `block-no-verify` hook | `~/.continue/permissions.yaml` exclusions | Denies `git ... --no-verify` and `core.hooksPath` overrides | | ||
| | `hooks/hooks.json` (curated 7) | `settings.json` hooks via an adapter | Opt in with `--hooks` (see [Limitations](#limitations)) | | ||
|
|
||
| A small always-on rule (`00-continue-compat.md`) maps Claude Code vocabulary onto `cn`. For example, `Grep` becomes `Search`, `Glob` becomes `List`, and "delegate to the planner agent" becomes "read `~/.continue/ecc/agents/planner.md` and follow it". | ||
|
|
||
| ## Prerequisites | ||
|
|
||
| - Node.js 18 or newer | ||
| - The Continue CLI: `npm i -g @continuedev/cli` | ||
| - A working model. Run `cn` once and finish its first-run setup (login or API key) **before** installing ECC. If you have no `~/.continue/config.yaml`, the installer creates one for `anthropic/claude-sonnet-4-6` that reads `ANTHROPIC_API_KEY`. | ||
|
|
||
| ## Install | ||
|
|
||
| ```bash | ||
| git clone https://github.com/sumitbiranje/ecc.git ~/ecc | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| cd ~/ecc | ||
| ./install-continue.sh | ||
| ``` | ||
|
|
||
| On Windows (PowerShell): | ||
|
|
||
| ```powershell | ||
| git clone https://github.com/sumitbiranje/ecc.git $HOME\ecc | ||
| cd $HOME\ecc | ||
| .\install-continue.ps1 | ||
| ``` | ||
|
|
||
| The default install is the `common` rules, the `core` skill profile (52 skills), all slash commands, all agent files and the guardrails. It goes into `~/.continue`, or `$CONTINUE_GLOBAL_DIR` if you set it. Your existing `config.yaml` is backed up to `config.yaml.ecc-backup` and ECC's lines are appended and tagged `# ecc-managed`. | ||
|
|
||
| Add the launchers to your `PATH`: | ||
|
|
||
| ```bash | ||
| echo 'export PATH="$HOME/.continue/ecc/bin:$PATH"' >> ~/.bashrc # or ~/.zshrc | ||
|
Comment on lines
+46
to
+49
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add Windows PATH instructions for the launchers. The guide supports PowerShell installation, but this PATH command applies only to Bash. The installer writes
|
||
| ``` | ||
|
|
||
| ### Common variations | ||
|
|
||
| ```bash | ||
| # Language rules for the stacks you use (see --list for all 21) | ||
| ./install-continue.sh --langs python,typescript | ||
|
|
||
| # A bigger skill set: core | developer | security | research | full | all | none | ||
| ./install-continue.sh --skills developer --add-skills docker-patterns | ||
|
|
||
| # MCP servers from mcp-configs/ (secrets come from env or ~/.continue/.env) | ||
| ./install-continue.sh --mcp context7,github | ||
|
|
||
| # Expose 8 core agents as cn subagents | ||
| ./install-continue.sh --subagents core --subagent-model anthropic/claude-sonnet-4-6 | ||
|
|
||
| # Local models (LM Studio / Ollama via an OpenAI-compatible endpoint) | ||
| ./install-continue.sh --subagents core --subagent-model openai/qwen2.5-coder \ | ||
| --api-base http://localhost:1234/v1 --api-key-secret LMSTUDIO_KEY | ||
|
|
||
| # Per-project rules, skills and agents in <project>/.continue (languages auto-detected) | ||
| ./install-continue.sh --scope project --project ~/code/my-app | ||
|
|
||
| # See what would change, or list languages, skill profiles and MCP servers | ||
| ./install-continue.sh --dry-run | ||
| ./install-continue.sh --list | ||
| ``` | ||
|
|
||
| Re-running the installer is safe. It replaces ECC's previous files and config entries instead of duplicating them, and removes skills you dropped from the selection. | ||
|
|
||
| ## Using it | ||
|
|
||
| ### Interactive (TUI) | ||
|
|
||
| ```bash | ||
| cd your-project | ||
| cn | ||
| ``` | ||
|
|
||
| - Type `/` to browse ECC commands such as `/plan add OAuth login`, `/code-review`, `/build-fix`, `/test-coverage`, `/security-scan` and `/refactor-clean`. Anything after the command name is passed to the prompt as its arguments. | ||
| - `/skills` lists installed skills. `/skill-tdd-workflow` loads one explicitly. Usually the model picks skills itself from their descriptions. | ||
| - `/ctx-dev`, `/ctx-review` and `/ctx-research` switch ECC's working context. | ||
| - `/ecc-sessions` is ECC's `/sessions`, renamed so that it does not shadow `cn`'s built-in command. | ||
|
|
||
| ### Agents | ||
|
|
||
| ```bash | ||
| ecc-agent list | ||
| ecc-agent code-reviewer "review the staged changes" | ||
| ecc-agent security-reviewer -p "audit src/auth" > audit.md # headless | ||
| ``` | ||
|
|
||
| `ecc-agent <name>` runs `cn --agent ~/.continue/ecc/agents/<name>.md`. The agent's tool list is mapped to `cn` tools, so a read-only reviewer stays read-only. | ||
|
|
||
| With `--subagents`, start `cn --beta-subagent-tool` and the main agent can hand work to `planner`, `code-reviewer`, `security-reviewer` and others in the background. Each subagent entry is only a few lines; it reads its full instructions from the agent file when it starts. That keeps the Subagent tool description small. | ||
|
|
||
| ### Headless and CI | ||
|
|
||
| `cn` expands `/slash` commands only in the TUI. For scripts, use the plain prompt files: | ||
|
|
||
| ```bash | ||
| ecc-prompt list | ||
| ecc-prompt code-review -p "focus on src/api" | ||
| # same as: cn -p --prompt ~/.continue/ecc/prompts/code-review.md "focus on src/api" | ||
| ``` | ||
|
|
||
| ### Guardrails | ||
|
|
||
| `~/.continue/permissions.yaml` gets two exclusions: `Bash(*--no-verify*)` and `Bash(*core.hooksPath*)`. `cn` denies matching commands in the TUI and in `-p` runs. **`--auto` overrides every permission policy**, these included. Skip them with `--no-guardrails`. | ||
|
|
||
| ## Update | ||
|
|
||
| ```bash | ||
| cd ~/ecc | ||
| git pull | ||
| ./install-continue.sh # with the same options you used before | ||
| ``` | ||
|
|
||
| To pull in new upstream ECC releases, sync your fork with `affaan-m/ECC` on GitHub first. | ||
|
|
||
| ## Uninstall | ||
|
|
||
| ```bash | ||
| ./install-continue.sh --uninstall | ||
| ./install-continue.sh --scope project --project ~/code/my-app --uninstall | ||
| ``` | ||
|
|
||
| This removes ECC's rules, skills, agents, prompt blocks, guardrails and hooks, and strips the `# ecc-managed` lines from `config.yaml`. Your own entries are left as they were. | ||
|
|
||
| ## Limitations | ||
|
|
||
| These are differences in what `cn` supports, not bugs in the conversion: | ||
|
|
||
| - **Hooks do not run yet.** `cn` 1.5.47 reads Claude-Code-style hooks from `settings.json`, but its tool loop never fires them. `--hooks` installs seven ECC hooks through `scripts/hooks/continue-hook-adapter.js`, which already normalises `cn` payloads (tool names, `filepath` versus `file_path`). They are inert until Continue wires hook events up. Session memory, cost tracking and the format/typecheck-on-stop hooks are therefore not available. The `--no-verify` protection is covered by the permissions file instead. | ||
| - **Rules are always on.** `cn` injects only always-apply rules, so a language pack applies to every file once you install it. Pick languages with `--langs`, or use `--scope project` per repository. | ||
| - **Skills cost context.** `cn` lists every installed skill's name and description in the Skills tool on each request. `core` costs about 4.5k tokens, `developer` about 10k and `all` about 25k. | ||
| - **Agent `model:` is ignored.** `cn` resolves agent-file models from the Continue Hub, so ECC's `sonnet`/`opus` aliases are dropped and the session model is used. MCP tools and `WebSearch` in an agent's tool list are dropped too, because agent files can only name Hub MCP servers. | ||
| - **Claude-only features** such as plugin marketplaces, the statusline and `/hookify` have no `cn` equivalent. Commands that depend on them still install but only partly work in `cn`. | ||
|
|
||
| ## Troubleshooting | ||
|
|
||
| - **`cn` asks for an Anthropic API key.** First-run onboarding has not completed. Finish it, or start with `cn --config ~/.continue/config.yaml`, then rerun the installer. | ||
| - **`Failed to load config`.** Run `cn --verbose` to see which block failed. Your pre-install config is in `~/.continue/config.yaml.ecc-backup`. | ||
| - **An MCP server fails to start.** Set its secrets (the installer prints the names) in your shell or in `~/.continue/.env`. Servers with placeholders, such as `filesystem` and `supabase`, need their block in `~/.continue/ecc/blocks/mcp/` edited. | ||
| - **A skill was skipped.** A skill with the same name already existed and was not installed by ECC. Pass `--force` to replace it. | ||
|
|
||
| ## Files written | ||
|
|
||
| ```text | ||
| ~/.continue/ | ||
| ├── config.yaml # + prompts / mcpServers / models entries (# ecc-managed) | ||
| ├── permissions.yaml # + guardrail exclusions | ||
| ├── rules/ecc/ # compat rule + common + chosen languages | ||
| ├── skills/<name>/ # selected skills | ||
| ├── settings.json # only with --hooks | ||
| └── ecc/ | ||
| ├── agents/*.md # cn agent files | ||
| ├── prompts/*.md # headless prompt files | ||
| ├── blocks/{prompts,mcp,subagents}/*.yaml | ||
| ├── bin/ecc-agent, ecc-prompt (+ .cmd) | ||
| └── install-manifest.json | ||
| ``` | ||
|
|
||
| The converter lives in `scripts/lib/continue-cli.js`. Its tests are `tests/lib/continue-cli.test.js`, `tests/hooks/continue-hook-adapter.test.js` and `tests/scripts/install-continue.test.js`. | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| #!/usr/bin/env pwsh | ||
| # install-continue.ps1 - install ECC into the Continue CLI (`cn`) on Windows. | ||
| # | ||
| # .\install-continue.ps1 | ||
| # .\install-continue.ps1 --langs python,typescript --skills developer | ||
| # .\install-continue.ps1 --help | ||
| # | ||
| # See CONTINUE-CLI.md. All options are passed to scripts/install-continue.js. | ||
|
|
||
| Set-StrictMode -Version Latest | ||
| $ErrorActionPreference = 'Stop' | ||
|
|
||
| $scriptDir = Split-Path -Parent $PSCommandPath | ||
| $installer = Join-Path -Path (Join-Path -Path $scriptDir -ChildPath 'scripts') -ChildPath 'install-continue.js' | ||
|
|
||
| if (-not (Get-Command node -ErrorAction SilentlyContinue)) { | ||
| Write-Error '[ECC] Node.js 18+ is required (https://nodejs.org).' | ||
| exit 1 | ||
| } | ||
|
|
||
| # SECURITY: --ignore-scripts blocks install-time scripts from dependencies. | ||
| if (-not (Test-Path -LiteralPath (Join-Path -Path $scriptDir -ChildPath 'node_modules'))) { | ||
| Write-Host '[ECC] Installing dependencies...' | ||
| Push-Location $scriptDir | ||
| try { | ||
| & npm install --ignore-scripts --no-audit --no-fund --loglevel=error | ||
| if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE } | ||
| } finally { | ||
| Pop-Location | ||
| } | ||
| } | ||
|
|
||
| if (-not (Get-Command cn -ErrorAction SilentlyContinue)) { | ||
| Write-Host '[ECC] Note: the Continue CLI is not on PATH yet. Install it with: npm i -g @continuedev/cli' | ||
| } | ||
|
|
||
| & node $installer @args | ||
| exit $LASTEXITCODE |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| #!/usr/bin/env bash | ||
| # install-continue.sh — install ECC into the Continue CLI (`cn`). | ||
| # | ||
| # ./install-continue.sh # global install, core skills | ||
| # ./install-continue.sh --langs python,typescript --skills developer | ||
| # ./install-continue.sh --help | ||
| # | ||
| # See CONTINUE-CLI.md. All options are passed to scripts/install-continue.js. | ||
|
|
||
| if ! (eval '[[ 1 == 1 ]]' >/dev/null 2>&1); then | ||
| exec bash "$0" "$@" | ||
| fi | ||
|
|
||
| set -euo pipefail | ||
|
|
||
| SCRIPT_PATH="$0" | ||
| while [ -L "$SCRIPT_PATH" ]; do | ||
| link_dir="$(cd "$(dirname "$SCRIPT_PATH")" && pwd)" | ||
| SCRIPT_PATH="$(readlink "$SCRIPT_PATH")" | ||
| [[ "$SCRIPT_PATH" != /* ]] && SCRIPT_PATH="$link_dir/$SCRIPT_PATH" | ||
| done | ||
| SCRIPT_DIR="$(cd "$(dirname "$SCRIPT_PATH")" && pwd)" | ||
|
|
||
| if ! command -v node >/dev/null 2>&1; then | ||
| echo "[ECC] Node.js 18+ is required (https://nodejs.org)." >&2 | ||
| exit 1 | ||
| fi | ||
|
|
||
| # SECURITY: --ignore-scripts blocks install-time scripts from dependencies. | ||
| if [ ! -d "$SCRIPT_DIR/node_modules" ]; then | ||
| echo "[ECC] Installing dependencies..." | ||
| (cd "$SCRIPT_DIR" && npm install --ignore-scripts --no-audit --no-fund --loglevel=error) | ||
| fi | ||
|
|
||
| if ! command -v cn >/dev/null 2>&1; then | ||
| echo "[ECC] Note: the Continue CLI is not on PATH yet. Install it with: npm i -g @continuedev/cli" | ||
| fi | ||
|
|
||
| if command -v cygpath >/dev/null 2>&1; then | ||
| NODE_SCRIPT="$(cygpath -w "$SCRIPT_DIR/scripts/install-continue.js")" | ||
| else | ||
| NODE_SCRIPT="$SCRIPT_DIR/scripts/install-continue.js" | ||
| fi | ||
|
|
||
| exec node "$NODE_SCRIPT" "$@" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -105,6 +105,10 @@ | |
| "hooks/", | ||
| "install.ps1", | ||
| "install.sh", | ||
| "install-continue.sh", | ||
| "install-continue.ps1", | ||
| "CONTINUE-CLI.md", | ||
| "scripts/install-continue.js", | ||
|
Comment on lines
+108
to
+111
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Include When a user runs the new installer from the npm package,
|
||
| "manifests/", | ||
| "mcp-configs/", | ||
| "plugins/ecc/", | ||
|
|
@@ -537,6 +541,7 @@ | |
| "coverage:python": "python3 -m pytest tests/ -q --cov=src --cov-report=term --cov-fail-under=80", | ||
| "coverage": "c8 --all --include=\"scripts/**/*.js\" --include=\"scripts/**/*.mjs\" --check-coverage --lines 80 --functions 80 --branches 80 --statements 80 --reporter=text --reporter=lcov node tests/run-all.js", | ||
| "build:opencode": "node scripts/build-opencode.js", | ||
| "install:continue": "node scripts/install-continue.js", | ||
| "prepack": "npm run build:opencode", | ||
| "dashboard": "python3 ./ecc_dashboard.py", | ||
| "dashboard:web": "node scripts/dashboard-web.js" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Require Node.js 20+ for the documented CLI installation.
The stated Node.js 18 minimum conflicts with the
@continuedev/clinpm installation requirement of Node.js 20+. A user following these prerequisites with Node.js 18 cannot complete the documentedcnsetup. Keep the ECC installer’s runtime requirement separate if it remains lower. (npmjs.com)