docs: updated overview & quickstart, uploaded gif

This commit is contained in:
joeytoday
2025-12-10 18:17:22 +08:00
parent a39b68a44f
commit d5fc8e390b
3 changed files with 50 additions and 78 deletions

View File

@@ -43,7 +43,7 @@ what are the key data models?
how is authentication handled?
```
> [!tip] Tips:
>[!tip] Tips:
>
> - Start with broad questions, then narrow down to specific areas
> - Ask about coding conventions and patterns used in the project
@@ -58,7 +58,7 @@ Suppose you need to locate code related to a specific feature or functionality.
```
find the files that handle user authentication
```
2. Get context on how components interact
```
@@ -95,7 +95,7 @@ suggest a few ways to fix the @ts-ignore in user.ts
update user.tsto add the null check you suggested
```
> [!tip] Tips:
> [!tip]
>
> - Tell Qwen Code the command to reproduce the issue and get a stack trace
> - Mention any steps to reproduce the error
@@ -110,13 +110,13 @@ Suppose you need to update old code to use modern patterns and practices.
```
find deprecated API usage in our codebase
```
2. Get refactoring recommendations
```
suggest how to refactor utils.js to use modern JavaScript features
```
3. Apply the changes safely
```
@@ -129,7 +129,7 @@ refactor utils.js to use ES 2024 features while maintaining the same behavior
run tests for the refactored code
```
> [!tip] Tips:
> [!tip]
>
> - Ask Qwen Code to explain the benefits of the modern approach
> - Request that changes maintain backward compatibility when needed
@@ -182,7 +182,7 @@ Then select "Create New subagent" and follow the prompts to define:
- Which tools it can access
- A system prompt describing the agent's role and behavior
> [!tip] Tips:
> [!tip]
>
> - Create project-specific subagents in `.qwen/agents/` for team sharing
> - Use descriptive `description` fields to enable automatic delegation
@@ -305,7 +305,7 @@ enhance the PR description with more context about the security improvements
add information about how these changes were tested
```
> [!tip] Tips:
> [!tip]
>
> - Ask Qwen Code directly to make a PR for you
> - Review Qwen Code's generated PR before submitting
@@ -335,7 +335,7 @@ improve the generated documentation with more context and examples
check if the documentation follows our project standards
```
> [!tip] Tips:
> [!tip]
>
> - Specify the documentation style you want (JSDoc, docstrings, etc.)
> - Ask for examples in the documentation
@@ -384,7 +384,7 @@ Generate CSS to match this design mockup
What HTML structure would recreate this component?
```
> [!tip] Tips:
> [!tip]
>
> - Use images when text descriptions would be unclear or cumbersome
> - Include screenshots of errors, UI designs, or diagrams for better context
@@ -416,7 +416,7 @@ Show me the data from @github: repos/owner/repo/issues
This fetches data from connected MCP servers using the format @server: resource. See [MCP](/mcp) for details.
> [!tip] Tips:
> [!tip]
>
> - File paths can be relative or absolute
> - @ file references add `QWEN.md` in the file's directory and parent directories to context
@@ -486,7 +486,7 @@ This displays an interactive conversation selector with a clean list view showin
Use arrow keys to navigate and press Enter to select a conversation. Press Esc to exit.
> [!tip] Tips:
> [!tip]
>
> - Conversation history is stored locally on your machine
> - Use `--continue` for quick access to your most recent conversation
@@ -547,7 +547,7 @@ cd ../project-feature-a
qwen
```
5. Run Qwen Code in another worktree
```bash
cd ../project-bugfix
@@ -564,7 +564,7 @@ git worktree remove ../project-feature-a
```
> [!tip] Tips:
> [!tip]
>
> - Each worktree has its own independent file state, making it perfect for parallel Qwen Code sessions
> - Changes made in one worktree won't affect others, preventing Qwen Code instances from interfering with each other
@@ -597,7 +597,7 @@ Suppose you want to use Qwen Code as a linter or code reviewer.
```
> [!tip] Tips:
> [!tip]
>
> - Use Qwen Code for automated code review in your CI/CD pipeline
> - Customize the prompt to check for specific issues relevant to your project
@@ -613,7 +613,7 @@ Suppose you want to pipe data into Qwen Code, and get back data in a structured
cat build-error.txt | qwen-code -p 'concisely explain the root cause of this build error' > output.txt
```
> [!tip] Tips:
> [!tip]
>
> - Use pipes to integrate Qwen-Code into existing shell scripts
> - Combine with other Unix tools for powerful workflows
@@ -646,8 +646,8 @@ cat log. txt | qwen-code -p 'parse this log file for errors' --output-format str
```
This outputs a series of JSON objects in real-time as Qwen Code processes the request. Each message is a valid JSON object, but the entire output is not valid JSON if concatenated.
> [!tip] Tips:
> [!tip]
>
> - Use `--output-format text` for simple integrations where you just need Qwen Code's response
> - Use `--output-format json` when you need the full conversation log
@@ -688,7 +688,7 @@ what are the limitations of Qwen Code?
>
> Qwen Code provides documentation-based answers to these questions. For executable examples and hands-on demonstrations, refer to the specific workflow sections above.
> [!tip] Tips:
> [!tip]
>
> - Qwen Code always has access to the latest Qwen Code documentation, regardless of the version you're using
> - Ask specific questions to get detailed answers

View File

@@ -7,15 +7,11 @@
Prerequisites:
- A [Qwen Code](https://chat.qwen.ai/auth?mode=register) account
- Requires [Node.js 20+](https://nodejs.org/download), you can use `node -v` to check the version. If it's not installed, use the following command to install it.
```bash
curl -qL https://www.npmjs.com/install.sh | sh
```
- Requires [Node.js 20+](https://nodejs.org/zh-cn/download), you can use `node -v` to check the version. If it's not installed, use the following command to install it.
### Install Qwen Code:
**NPM**(recommended)
⭐️ **NPM**(recommended)
```bash
npm install -g @qwen-code/qwen-code@latest
@@ -27,6 +23,8 @@ npm install -g @qwen-code/qwen-code@latest
brew install qwen-code
```
![](https://gw.alicdn.com/imgextra/i4/O1CN01eBPcmt27ezX0uaIn1_!!6000000007823-1-tps-1152-646.gif)
### Start using Qwen Code:
```bash
@@ -34,7 +32,15 @@ cd your-project
qwen
```
You'll be prompted to log in on first use. That's it! [Continue with Quickstart (5 mins) →](/quickstart)
Let's start with understanding your codebase. Try one of these commands:
```
what does this project do?
```
![](https://gw.alicdn.com/imgextra/i1/O1CN01KUl70h277YcVQRS0Z_!!6000000007750-1-tps-1152-646.gif)
You'll be prompted to log in on first use. That's it! [Continue with Quickstart (5 mins) →](/users/quickstart)
> [!tip]
>
@@ -48,11 +54,11 @@ You'll be prompted to log in on first use. That's it! [Continue with Quickstart
* **Build features from descriptions**: Tell Qwen Code what you want to build in plain language. It will make a plan, write the code, and ensure it works.
* **Debug and fix issues**: Describe a bug or paste an error message. Qwen Code will analyze your codebase, identify the problem, and implement a fix.
* **Navigate any codebase**: Ask anything about your team's codebase, and get a thoughtful answer back. Qwen Code maintains awareness of your entire project structure, can find up-to-date information from the web, and with [MCP](/mcp) can pull from external datasources like Google Drive, Figma, and Slack.
* **Navigate any codebase**: Ask anything about your team's codebase, and get a thoughtful answer back. Qwen Code maintains awareness of your entire project structure, can find up-to-date information from the web, and with [MCP](/users/features/mcp) can pull from external datasources like Google Drive, Figma, and Slack.
* **Automate tedious tasks**: Fix fiddly lint issues, resolve merge conflicts, and write release notes. Do all this in a single command from your developer machines, or automatically in CI.
## Why developers love Qwen Code
* **Works in your terminal**: Not another chat window. Not another IDE. Qwen Code meets you where you already work, with the tools you already love.
* **Takes action**: Qwen Code can directly edit files, run commands, and create commits. Need more? [MCP](/mcp) lets Qwen Code read your design docs in Google Drive, update your tickets in Jira, or use *your* custom developer tooling.
* **Takes action**: Qwen Code can directly edit files, run commands, and create commits. Need more? [MCP](/users/features/mcp) lets Qwen Code read your design docs in Google Drive, update your tickets in Jira, or use *your* custom developer tooling.
* **Unix philosophy**: Qwen Code is composable and scriptable. `tail -f app.log | qwen -p "Slack me if you see any anomalies appear in this log stream"` *works*. Your CI can run `qwen -p "If there are new text strings, translate them into French and raise a PR for @lang-fr-team to review"`.

View File

@@ -20,10 +20,6 @@ To install Qwen Code, use one of the following methods:
Requires [Node.js 20+](https://nodejs.org/download), you can use `node -v` check the version. If it's not installed, use the following command to install it.
```bash
curl -qL https://www.npmjs.com/install.sh | sh
```
If you have [Node.js or newer installed](https://nodejs.org/en/download/):
```sh
@@ -71,30 +67,14 @@ cd /path/to/your/project
qwen
```
You'll see the Qwen Code welcome screen with your session information, recent conversations, and latest updates. Type `/help` for available commands or `/resume` to continue a previous conversation.
![](https://img.alicdn.com/imgextra/i3/O1CN01PwceZB1esA42wuQQH_!!6000000003926-2-tps-2104-1592.png)
You'll see the Qwen Code welcome screen with your session information, recent conversations, and latest updates. Type `/help` for available commands.
## Chat with Qwen Code
### Ask your first question
Let's start with understanding your codebase. Try one of these commands:
```
what does this project do?
```
Qwen Code will analyze your files and provide a summary. You can also ask more specific questions:
```
what technologies does this project use?
```
```
where is the main entry point?
```
```
explain the folder structure
```
@@ -105,14 +85,6 @@ You can also ask Qwen Code about its own capabilities:
what can Qwen Code do?
```
```
how do I use slash commands in Qwen Code?
```
```
can Qwen Code work with Docker?
```
> [!note]
> Qwen Code reads your files as needed - you don't have to manually add context. Qwen Code also has access to its own documentation and can answer questions about its features and capabilities.
@@ -218,27 +190,21 @@ review my changes and suggest improvements
Here are the most important commands for daily use:
| Command | What it does | Example |
| --------------------- | ------------------------------------------------------ | ---------------------------------- |
| `qwen` | start Qwen Code | `qwen` |
| `/chat` | Manually save and restore conversation history | Requires sub-commands |
| → `save <label>` | Save current conversation state | `/chat save Feature Ideation` |
| → `resume <label>` | Restore conversation from saved point | `/chat resume Feature Ideation` |
| → `list` | List all recoverable conversation labels | `/chat list` |
| → `delete <label>` | Delete saved conversation checkpoint | `/chat delete Feature Ideation` |
| → `share [file]` | Export conversation as Markdown or JSON | `/chat share Discussion Record.md` |
| `/summary` | Generate project summary based on conversation history | `/summary` |
| `/compress` | Replace chat history with summary to save Tokens | `/compress` |
| `/clear` | Clear terminal screen content | `/clear` (shortcut: `Ctrl+L`) |
| `/theme` | Change Qwen Code visual theme | `/theme` |
| `/language` | View or change language settings | `/language` |
| → `ui [language]` | Set UI interface language | `/language ui zh-CN` |
| → `output [language]` | Set LLM output language | `/language output Chinese` |
| `/help` | Display help information for available commands | `/help` or `/?` |
| `/auth` | Change authentication method | `/auth` |
| `/quit` | Exit Qwen Code immediately | `/quit` or `/exit` |
| Command | What it does | Example |
| --------------------- | ------------------------------------------------------ | ----------------------------- |
| `qwen` | start Qwen Code | `qwen` |
| `/summary` | Generate project summary based on conversation history | `/summary` |
| `/compress` | Replace chat history with summary to save Tokens | `/compress` |
| `/clear` | Clear terminal screen content | `/clear` (shortcut: `Ctrl+L`) |
| `/theme` | Change Qwen Code visual theme | `/theme` |
| `/language` | View or change language settings | `/language` |
| → `ui [language]` | Set UI interface language | `/language ui zh-CN` |
| → `output [language]` | Set LLM output language | `/language output Chinese` |
| `/help` | Display help information for available commands | `/help` or `/?` |
| `/auth` | Change authentication method | `/auth` |
| `/quit` | Exit Qwen Code immediately | `/quit` or `/exit` |
See the [CLI reference](/cli-reference) for a complete list of commands.
See the [CLI reference](/users/reference/cli-reference) for a complete list of commands.
## Pro tips for beginners
@@ -262,7 +228,7 @@ See the [CLI reference](/cli-reference) for a complete list of commands.
```
build a dashboard showing products that are most frequently returned by our UK customers
```
- Save time with shortcuts
- Press `?` to see all available keyboard shortcuts
- Use Tab for command completion