Coder Social home page Coder Social logo

dofy / learn-vim Goto Github PK

View Code? Open in Web Editor NEW
1.7K 1.7K 237.0 164 KB

Learning Vim. A Hands-On Tutorial of Vim.

Home Page: https://dofy.gitbook.io/learn-vim/

License: Creative Commons Zero v1.0 Universal

JavaScript 29.29% Vim Script 70.71%
beginner book chinese editor education learning programming tips tutorial vi vim

learn-vim's Introduction

Vim Hands-On Tutorial (Learning Vi and Vims)

GitHub Repo stars GitHub GitHub contributors GitHub commit activity (branch)

🇺🇸 English | 🇨🇳 简体中文

Intro

In my personal experience of learning Vim, it is very difficult to learn Vim by reading documentation or watching other people operate it. You have to be in the real world, in real scenarios, to familiarize yourself with the commands and master them.

Therefore, to meet the needs of learning and operating at the same time, all the files in the project are in Markdown format, which can be read as an explanation document, and can also be opened in Vim. You can read it as an explanatory document, and you can also use Vim to open the files for actual operation (the latter is recommended).

How to Use

  1. clone project to local
git clone https://github.com/dofy/learn-vim.git
  1. go to the project folder
cd learn-vim/en
  1. open the file chapter01.md in Vim
vim chapter01.md

Formatting Rules

## Major titles represent a large category

### Subtitles represent subcategories under this major category

Text without any formatting is a normal description for reading purposes only.

> The text embedded in the quoted block is an instruction to operate, and you
> can follow what is mentioned in it
>
> Also operators or commands are included in symbols like `:w`.

The < and > in commands such as f<X> do not need to be typed, <X> represents a
variable, i.e. you can type fa or fb or fC

_Note: Commands are case-sensitive (matters requiring attention appear in
symbols such as the current line)_

Note

If you already have your own .vimrc file (refer to Chapter 4) and have changed some of the defaults in it, it may cause some operations to not match the tutorial. In this case, you can run Vim with the following command:

# Do not load the configuration file
vim -u NONE
# Load a specific configuration file
vim -u <filename>

Index

Basic operations

  1. Chapter 1: Cursor Movement
  2. Chapter 2: Opening Files, Finding Content
  3. Chapter 3: Modify and Save Documents
  4. Chapter 4: Some Tips
  5. Chapter 5: Split Screen and Tabs
  6. Chapter 6: Block Operations
  7. Chapter 7: Macros in Vim

Additional content

  1. Vim Modes
  2. Vim plugins
  3. Plugin Recommendations
    1. NERDTree
    2. EasyAlign
    3. Airline & Themes
    4. surround.vim

Note

  • In the tutorials, you can navigate to the next chapter or related chapters, and locate the file name to open it by executing gf (goto file). Related files
  • You can always open the relevant chapter to view, and then use :bp to go back to the previous file (this command will (This command is covered in Chapter 2).
  • You may get a file not saved error when you exit the tutorial with :q or :qa, try adding ! to the end of the command!

Recommend a few Vim configurations

Recommends a couple of other excellent Vim tutorials

Cheatsheets

Vim Cheat Sheet

A Great Vim Cheat Sheet

003

004

005

Star History

Star History Chart

Thanks again for your interest! If you love, please share. Love life, love VIM!

learn-vim's People

Contributors

anamewing avatar byr-gdp avatar codeditor2 avatar dofy avatar fighterleslie avatar geekpany avatar jason5ng32 avatar leoleohu avatar likev avatar sinvilcorpse avatar vimtutor avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

learn-vim's Issues

进入 Ex mode 后如何退出?

测试环境 Mac zsh

有种说法是输入 visual 可恢复,但测试效果是"分屏",即屏幕右半部分回到了原来的文档内容,左半部分依旧是 Ex mode 的目录树。

尝试了发现 :bd 可以返回,但仅仅是我本地测试可以。
请教那种做法更好?

请问 md文件编码 是什么?

刚刚接触vim,在vps上安装vim,clone之后,vim打开文件发现中文出现类似于麻将块的乱码,使用putty登陆,请问怎么解决?

在块粘贴时遇到的问题.

ctrl+v,选中了多行,y后
移到需要粘贴的地方,但下面还有其他代码,这时如果用p,会把下面的代码与复制的内容合并起来(有点类似replace),我想在粘贴的时候把下面的代码依次往下移,怎么操作呢? 求教.

一天摸完,感谢.

非常感谢,以后决定抛弃sublime text,估计接下来会有一段阵痛期,熬过了就好了-_-.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.