Elffuss BraidHub

kikocis/continue public

406467d04db9 · 2.7 KiBRawPermalink
1---
2title: "Install Continue CLI"
3description: "Get Continue CLI installed and configured for command-line AI coding assistance and automation"
4sidebarTitle: "Install"
5---
6
7<Info>
8 Make sure you have [Node.js 18 or higher
9 installed](https://nodejs.org/en/download/).
10</Info>
11
12## Installation
13
14Install Continue CLI globally using npm:
15
16```bash
17npm i -g @continuedev/cli
18```
19
20## Two Ways to Use Continue CLI
21
22<Info>
23 **Quick Overview**: Continue CLI works in two modes - interactive
24 conversations or async, automated commands.
25</Info>
26
27<Tabs>
28<Tab title="REPL Mode">
29**Interactive development sessions**
30
31Start a conversation with AI in your terminal:
32
33```bash
34cn
35> @src/app.js Generate unit tests for this component
36```
37
38Perfect for exploration, debugging, and iterative development.
39
40</Tab>
41
42<Tab title="Continuous AI Mode">
43**Automation and scripting**
44
45Single commands that return results:
46
47```bash
48cn -p "Generate a commit message for current changes"
49cn -p "Review the last 5 commits for issues"
50```
51
52Perfect for CI/CD, git hooks, and automated workflows.
53
54</Tab>
55</Tabs>
56
57## Setup for CLI (REPL Mode)
58
59For interactive development and exploration:
60
61<Steps>
62<Step title="Login to Continue CLI">
63```bash
64cn login
65```
66This will open your browser to authenticate with Continue Hub.
67</Step>
68
69<Step title="Test Interactive Mode">
70Start an interactive session:
71```bash
72cn
73```
74
75Try asking a question:
76
77```
78> Tell me about the CLI
79```
80
81</Step>
82</Steps>
83
84## Setup for CLI (Continuous AI Mode)
85
86For automation workflows and scripting:
87
88<Steps>
89<Step title="Get API Key for Automation">
90For automation workflows, get an API key:
911. Visit [Continue Hub API Keys](https://hub.continue.dev/settings/api-keys)
922. Click **"+ New API Key"**
933. Copy the API key immediately (you won't see it again!)
944. Login using your Continue account
95</Step>
96
97<Step title="Add Secrets for Workflows">
98Store secure credentials for CLI workflows:
991. Visit [Continue Hub Secrets](https://hub.continue.dev/settings/secrets)
1002. Add your API keys and sensitive data
1013. Reference in configurations with `${{ secrets.SECRET_NAME }}`
102</Step>
103
104<Step title="Test Async Mode">
105Try async mode for automation:
106```bash
107cn -p "Generate a conventional commit message for the current git changes"
108```
109</Step>
110</Steps>
111
112## What's Next?
113
114<CardGroup cols={2}>
115<Card title="Quick Start Guide" icon="rocket" href="/cli/quick-start">
116 Learn basic usage with practical examples
117</Card>
118
119<Card title="Create your first workflow" icon="gear" href="/guides/posthog-github-continuous-ai">
120 Build automated workflows with Continue CLI
121</Card>
122</CardGroup>
123
124## Getting Help
125
126If you encounter issues:
127
128- Ask for help in [our discussions](https://github.com/continuedev/continue/discussions)
129- Report bugs on [GitHub](https://github.com/continuedev/continue)