当前位置:网站首页>vim跨行匹配搜索
vim跨行匹配搜索
2022-07-26 08:15:00 【cy413026】
目录
vim跨行搜索 匹配_XtremeDV的博客-CSDN博客_vim跨行匹配
/^abcd表示在一行的开头找到abcd,/abcd$表示在一行的结尾找到abcd。 但是,在/abcd^efgh和/abcd$efgh中,^和$只是普通字符,没有特殊含义。 相比之下,以下每一项在搜索模式中都具有特殊的含义。
\ n换行符(行尾)
\ _s是一个空格(空格或制表符)或换行符
\ _ ^开始一行(零宽度)
\ _ $一行的结束(零宽度)
\ _. 任何字符,包括换行符
示例:
(1) /abcd\n*efgh
查找abcd,接着是零个或多个换行符,然后是efgh。
查找abcdefgh或abcd后跟空行和efgh。
空行必须是空的(没有空格或制表符)。
(2) /abcd\_s*efgh
查找abcd后面跟随任何空格或换行符然后efgh。
查找abcdefgh或abcd后跟空行和efgh。
空行可以包含任意数量的空格或制表符。
(3) /abcd\_$\_s*efgh
在行末查找abcd,后面跟随任何空格或换行符,然后efgh。
abcd后面必须没有字符(换行符除外)。
在efgh之前,可以有任意数量的空格,制表符或换行符。
(4) /abcd\_s*\_^efgh
查找abcd后跟任何空格或换行符,然后在efgh开始一行。
在efgh之前,不得有任何字符(除了换行符)。
abcd后可以有任意数量的空格,制表符或换行符。
(5) /abcd\_.\{-}efgh
找到abcd后跟任何字符或换行符(尽可能少),然后efgh。这种就是abcd和efgh之间可以跨越多行中间可以是任何字符
查找abcdefgh或abcd后跟任何字符,然后选择efgh。
边栏推荐
- Zroi easy sum (generating function, block, DP, combination, polynomial)
- 第四天作业
- Burp suite Chapter 6 how to use burp spider
- sed作业
- Matlab drawing black spots on two / three-dimensional drawings
- 第三天作业
- A clear summary and configuration example of GPON has been highlighted
- R language foundation
- Burp Suite-第三章 如何使用Burp Suite代理
- Shell第二天作业
猜你喜欢

Burp suite Chapter 8 how to use burp intruder

Burp suite Chapter 4 advanced options for SSL and proxy

Spotty music data client_ ID account

Matlab-二/三维图上绘制黑点

全网最全:Mysql六种约束详解

2022-07-13 group 5 Gu Xiangquan's learning notes day06

苹果强硬新规:用第三方支付也要抽成,开发者亏大了!

Excel file reading and writing (creation and parsing)

The most complete network: detailed explanation of six constraints of MySQL

99 multiplication table and inverted triangle 99 multiplication table
随机推荐
随机分布学习笔记
JSP implicit object servlet object
[xshell7 free download and installation]
Burp suite Chapter 8 how to use burp intruder
Why don't you tell me what long polling is?
awk作业
Sed job
万字长文 | 深入理解 OpenFeign 的架构原理
通用 DAO 接口设计
A clear summary and configuration example of GPON has been highlighted
分享高压超低噪声LDO测试结果(High Voltage Ultra-low Noise LDO)
If the thread crashes, why doesn't it cause the JVM to crash? What about the main thread?
Dev gridcontrol captures key events
【EndNote】文献模板编排语法详解
Strtus2历史漏洞复现
Traversal mode of list, set, map, queue, deque, stack
2022/7/11 exam summary
Day 4 homework
Using ordered dictionary to copy pcap files
Use js to count the number of occurrences of each string in the string array, and format it into an object array.