> For the complete documentation index, see [llms.txt](https://dofy.gitbook.io/learn-vim/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dofy.gitbook.io/learn-vim/claude.md).

# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## Project Overview

This is a bilingual Vim hands-on tutorial repository. All content is in Markdown format — files serve dual purpose: readable documentation and actual files to practice Vim commands on.

## Repository Structure

```
learn-vim/
├── zh-CN/          # Simplified Chinese tutorial
│   ├── chapter01–07.md
│   ├── vim-modes.md
│   ├── vim-plugin.md
│   ├── vimrc.vim   # Sample .vimrc configuration
│   └── plugins/    # Plugin-specific tutorials (NERDTree, EasyAlign, Airline, surround.vim)
└── en/             # English tutorial (mirrors zh-CN structure)
```

Both language directories are structurally identical. `chapter04-demo.js` exists in both as a practice file for the tips chapter.

## Content Conventions

* `## Major titles` = top-level category
* `### Subtitles` = subcategory
* Plain text = description only (not interactive)
* `> Blockquote` = actionable instruction for the reader to perform in Vim
* Commands in backticks like `:w` — angle brackets like `<X>` denote variables, not literal characters
* All commands are case-sensitive

## Editing Guidelines

* Keep `zh-CN/` and `en/` in sync — changes to one language should be mirrored to the other
* Chapter files contain navigation links using filenames (readers use `gf` in Vim to follow them); keep filenames stable
* The `vimrc.vim` file is a reference configuration, not executed by the tutorial itself


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://dofy.gitbook.io/learn-vim/claude.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
