linux换行符替换成tab,Notepad++替换格式符号(如换行符、Tab符等)(示例代码)

20200524163242640255.png

(前提是要选中 正则表达式模式)

查找目标

替换为

说明

,

在行尾加上逗号

替换为空,即合并多行内容为一行

把 windows 下的换行符替换为 linux 下的换行符

替换为空,即把 windows 下的换行符替换为 Mac 下的换行符

,

把逗号全部替换成换行

去掉空行

1ss

1

去掉 1 后的两个空格,其中一个 s 表示一个空格

1两个半角空格

1

可以直接在 1 后跟两个半角空格来匹配,跟上面 s 是一样的效果

在每行行首添加制表符,即四个半角空格的效果

版权声明:本文为CSDN博主「媛测」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。

原文链接:https://blog.csdn.net/lijing742180/java/article/details/85174564

Extended Search Mode

In extended mode, these escape sequences (a backslash followed by a single character and optional material) have special meaning, and will not be interpreted literally.

: the Line Feed control character LF (ASCII 0x0A)

: The Carriage Return control character CR (ASCII 0x0D)

: the TAB control character (ASCII 0x09)

: the NUL control character (ASCII 0x00)

: the literal backalash character (ASCII 0x05C)

: the binary representation of a byte, made of 8 digits which are either 1’s or 0’s. ?

o: the octal representation of a byte, made of 3 digits in the 0-7 range

d: the decimal representation of a byte, made of 3 digits in the 0-9 range

x: the hexadecimal representation of a byte, made of 2 digits in the 0-9, A-F/a-f range.

u: The hexadecimal representation of a two byte character, made of 4 digits in the 0-9, A-F/a-f range. In Unicode builds, finds a Unicode character (for instance, u2020 matches the ? char, in an UTF-8 encoded file). In ANSI builds, finds characters requiring two bytes, like in the Shift-JIS encoding. ?

?NOTE: While some of these Extended Search Mode escape sequences look like regular expression escape sequences, they are not identical. Ones marked with ? are different from or not available in regular expressions.

来源: https://npp-user-manual.org/docs/searching/#extended-search-mode

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值